2002-01-20 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
+ * lyx_gui.C (init): give the toolbar tooltips a normal font.
+
+ * lyxfunc.C (getStatus): handle LFUN_LAYOUT like
+ LFUN_LAYOUT_PARAGRAPHS.
+
* tabular.C (GetCellFromInset): new method. Finds an inset in a
tabular. It is possible to provide a possible cell, which will
typically be the actcell from the corresponding insettabular
+2002-01-20 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
+
+ * Toolbar_pimpl.C (update): disable layout combox when LFUN_LAYOUT
+ is disabled
+
+ * combox.C (activate):
+ (deactivate): change color of labels to reflect the state of the
+ combox
+
2002-01-16 Herbert Voss <voss@lyx.org>
* FormExternal.C (build): activate apply/ok-button when something
}
else
fl_activate_object(p->icon);
+ } else if (p->action == ToolbarDefaults::LAYOUTS && combox) {
+ if (owner->getLyXFunc()->getStatus(LFUN_LAYOUT).disabled())
+ combox->deactivate();
+ else
+ combox->activate();
}
}
}
void Combox::activate()
{
- if (browser) fl_activate_object(browser);
- if (button) fl_activate_object(button);
- if (label) fl_activate_object(label);
+ if (browser)
+ fl_activate_object(browser);
+ if (button) {
+ fl_activate_object(button);
+ fl_set_object_lcol(button, FL_BLACK);
+ }
+ if (label) {
+ fl_activate_object(label);
+ fl_set_object_lcol(label, FL_BLACK);
+ }
}
void Combox::deactivate()
{
- if (browser) fl_deactivate_object(browser);
- if (button) fl_deactivate_object(button);
- if (label) fl_deactivate_object(label);
+ if (browser)
+ fl_deactivate_object(browser);
+ if (button) {
+ fl_deactivate_object(button);
+ fl_set_object_lcol(button, FL_INACTIVE);
+ }
+ if (label) {
+ fl_deactivate_object(label);
+ fl_set_object_lcol(label, FL_INACTIVE);
+ }
}
fl_setpup_fontsize(FL_NORMAL_SIZE);
fl_setpup_color(FL_MCOL, FL_BLACK);
fl_set_goodies_font(FL_NORMAL_STYLE, FL_NORMAL_SIZE);
+#if FL_REVISION < 89
+ fl_set_oneliner_font(FL_NORMAL_STYLE, FL_NORMAL_SIZE);
+#else
+ fl_set_tooltip_font(FL_NORMAL_STYLE, FL_NORMAL_SIZE);
+#endif
// all lyxrc settings has to be done here as lyxrc has not yet
// been read when the GUI is created (Jug)
&& !tli->getFirstLockingInsetOfType(Inset::TABULAR_CODE));
break;
+ case LFUN_LAYOUT:
case LFUN_LAYOUT_PARAGRAPH: {
Inset * inset = TEXT(false)->cursor.par()->inInset();
disable = inset && inset->forceDefaultParagraphs(inset);