+2002-02-06 Angus Leeming <a.leeming@ic.ac.uk>
+
+ Stabilise the tooltip interface and get Jürgen's patch to work ;-)
+
+ * Tooltips.[Ch]: new files. A wrapper to the tooltip code with a nice
+ clean interface. Means that FormBase, FormBaseDeprecated and
+ Tollbar_pimpl can all use the same code to have tooltips. No bloat.
+
+ * FormBase.C: add a Tooltips instance and interface with it.
+ (setTooltipLevel): removed. Replaced by fillTooltipChoice and
+ setTooltipLevel(ob).
+ (getVerboseTooltip, getMinimalTooltip) now passed a const FL_OBJECT.
+
+ * FormBibtex.[Ch]:
+ * FormCitation.[Ch]:
+ * FormTexinfo.[Ch]:
+ * Makefile.am: altered appropriately.
+
+2002-02-06 Juergen Spitzmueller <j.spitzmueller@gmx.de>
+
+ * forms/form_texinfo.fd:
+ * forms/form_bibtex.fd:
+ * forms/form_citation.fd: delete text_info field again, add help choice
+
+ * FormBibtex.[Ch]:
+ * FormCitation.[Ch]:
+ * FormTexinfo.[Ch]: Implement new Tooltip behaviour.
+
2002-02-06 Angus Leeming <a.leeming@ic.ac.uk>
* FormBase.[Ch]: can now chose the verbosity of the tooltip through
#include "FormBase.h"
#include "xformsBC.h"
#include "support/LAssert.h"
+#include "Tooltips.h"
#include "xforms_helpers.h" // formatted
-#if FL_REVISION < 89
-
-namespace {
-
-int TooltipHandler(FL_OBJECT *ob, int event);
-
-void TooltipTimerCB(FL_OBJECT * timer, long data);
-
-}
-
-extern "C" {
-
-static int C_FormBaseTooltipHandler(FL_OBJECT * ob, int event,
- FL_Coord, FL_Coord, int, void *)
-{
- return TooltipHandler(ob, event);
-}
-
-static void C_FormBaseTooltipTimerCB(FL_OBJECT * ob, long data)
-{
- TooltipTimerCB(ob, data);
-}
-
-}
-
-#endif // FL_REVISION < 89
-
-
extern "C" {
// Callback function invoked by xforms when the dialog is closed by the
FormBase::FormBase(ControlButtons & c, string const & t, bool allowResize)
: ViewBC<xformsBC>(c), minw_(0), minh_(0), allow_resize_(allowResize),
- title_(t), warning_posted_(false), tooltip_level_(VERBOSE_TOOLTIP)
+ title_(t), warning_posted_(false), tooltip_level_(NO_TOOLTIP)
{
-#if FL_REVISION < 89
- tooltip_timer_ = 0;
-#endif
+ tooltip_ = new Tooltips;
+ tooltip_->getTooltip.connect(SigC::slot(this, &FormBase::getTooltip));
}
+FormBase::~FormBase()
+{
+ delete tooltip_;
+}
+
void FormBase::redraw()
{
if (form() && form()->visible)
void FormBase::setTooltipHandler(FL_OBJECT * ob)
{
- lyx::Assert(ob);
-
-#if FL_REVISION < 89
- if (!tooltip_timer_) {
- fl_addto_form(form());
- tooltip_timer_ = fl_add_timer(FL_HIDDEN_TIMER, 0, 0, 0, 0, "");
- fl_end_form();
- }
-
- fl_set_object_posthandler(ob, C_FormBaseTooltipHandler);
- ob->u_cdata = reinterpret_cast<char *>(tooltip_timer_);
-
-#else
- string const help(getTooltip(ob));
- if (!help.empty())
- fl_set_object_helper(ob, help.c_str());
-#endif // FL_REVISION < 89
+ tooltip_->activateTooltip(ob);
}
-string const FormBase::getTooltip(FL_OBJECT * ob) const
+string FormBase::getTooltip(FL_OBJECT const * ob)
{
lyx::Assert(ob);
}
-void FormBase::setTooltipLevel(TooltipLevel level)
+/// Fill the tooltips chooser with the standard descriptions
+void FormBase::fillTooltipChoice(FL_OBJECT * ob)
+{
+ lyx::Assert(ob && ob->objclass == FL_CHOICE);
+
+ fl_clear_choice(ob);
+ fl_addto_choice(ob, _(" None | Normal | Verbose "));
+
+ switch(tooltip_level_){
+ case NO_TOOLTIP:
+ fl_set_choice(ob, 1);
+ break;
+ case MINIMAL_TOOLTIP:
+ fl_set_choice(ob, 2);
+ break;
+ case VERBOSE_TOOLTIP:
+ fl_set_choice(ob, 3);
+ break;
+ }
+}
+
+
+void FormBase::setTooltipLevel(FL_OBJECT * ob)
{
- tooltip_level_ = level;
+ lyx::Assert(ob && ob->objclass == FL_CHOICE &&
+ fl_get_choice_maxitems(ob) == 3);
+
+ switch(fl_get_choice(ob)){
+ case 1:
+ tooltip_level_ = NO_TOOLTIP;
+ break;
+ case 2:
+ tooltip_level_ = MINIMAL_TOOLTIP;
+ break;
+ case 3:
+ tooltip_level_ = VERBOSE_TOOLTIP;
+ break;
+ }
}
}
} // extern "C"
-
-
-#if FL_REVISION < 89
-
-namespace {
-
-void TooltipTimerCB(FL_OBJECT * timer, long data)
-{
- FL_OBJECT * ob = reinterpret_cast<FL_OBJECT*>(data);
- lyx::Assert(ob && ob->form);
-
- string const help = GetForm(timer)->getTooltip(ob);
- if (help.empty())
- return;
-
- fl_show_oneliner(help.c_str(),
- ob->form->x + ob->x,
- ob->form->y + ob->y + ob->h);
-}
-
-
-// post_handler for bubble-help (Matthias)
-int TooltipHandler(FL_OBJECT *ob, int event)
-{
- lyx::Assert(ob);
- FL_OBJECT * timer = reinterpret_cast<FL_OBJECT *>(ob->u_cdata);
- lyx::Assert(timer);
-
- // We do not test for empty help here, since this can never happen
- if (event == FL_ENTER){
- fl_set_object_callback(timer,
- C_FormBaseTooltipTimerCB,
- reinterpret_cast<long>(ob));
- fl_set_timer(timer, 1);
- }
- else if (event != FL_MOTION){
- fl_set_timer(timer, 0);
- fl_hide_oneliner();
- }
- return 0;
-}
-
-} // namespace anon
-
-#endif // FL_REVISION < 89
#include "ButtonPolicies.h"
class xformsBC;
-
+class Tooltips;
/** This class is an XForms GUI base class.
*/
-class FormBase : public ViewBC<xformsBC>
+class FormBase : public ViewBC<xformsBC>, public SigC::Object
{
public:
///
///
FormBase(ControlButtons &, string const &, bool allowResize);
///
- virtual ~FormBase() {}
+ virtual ~FormBase();
/** input callback function.
Invoked only by C_FormBaseInputCB and by C_FormBasePrehandler */
void FeedbackCB(FL_OBJECT *, int event);
/** Return the tooltip dependent on the value of tooltip_level_
- Invoked only by setTooltipHandler and by TooltipTimerCB */
- string const getTooltip(FL_OBJECT *) const;
+ currently non-const becuase it gets connected to a SigC::slot */
+ string getTooltip(FL_OBJECT const *);
protected:
/// Build the dialog
/// Create the dialog if necessary, update it and display it.
void show();
- /// Set's how verbose the tooltips are going to be
- void setTooltipLevel(TooltipLevel level);
-
/// Prepare the way to produce a tooltip when the mouse is over ob.
void setTooltipHandler(FL_OBJECT * ob);
clear_feedback(). */
void setWarningPosted(bool);
+ /** Fill the tooltips chooser with the standard descriptions
+ and set it to the tooltips_level_ */
+ void fillTooltipChoice(FL_OBJECT *);
+ /// Set tooltips_level_ from the chooser.
+ void setTooltipLevel(FL_OBJECT *);
+
private:
/// Pointer to the actual instantiation of xform's form
virtual FL_FORM * form() const = 0;
virtual void redraw();
/// These methods can be overridden in the daughter classes.
- virtual string const getMinimalTooltip(FL_OBJECT *) const
+ virtual string const getMinimalTooltip(FL_OBJECT const *) const
{ return string(); }
- virtual string const getVerboseTooltip(FL_OBJECT *) const
+ virtual string const getVerboseTooltip(FL_OBJECT const *) const
{ return string(); }
/// Post feedback for ob. Defaults to nothing
/** Variable used to decide whether to remove the existing feedback
message or not (if it is infact a warning) */
bool warning_posted_;
- /// Enables tooltips for crappy GUI libraries...
-#if FL_REVISION < 89
- FL_OBJECT * tooltip_timer_;
-#endif
+ ///
+ Tooltips * tooltip_;
/// How verbose are the tooltips?
TooltipLevel tooltip_level_;
};
{
dialog_.reset(build_bibtex());
+ // the help choice
+ fillTooltipChoice(dialog_->choice_help);
fl_set_input_return(dialog_->database, FL_RETURN_CHANGED);
fl_set_input_return(dialog_->style, FL_RETURN_CHANGED);
bc().addReadOnly(dialog_->style);
bc().addReadOnly(dialog_->radio_bibtotoc);
- // set up the feedback mechanism
- setPrehandler(dialog_->database_browse);
- setPrehandler(dialog_->database);
- setPrehandler(dialog_->style_browse);
- setPrehandler(dialog_->style);
- setPrehandler(dialog_->radio_bibtotoc);
+ // set up the help mechanism
+ setTooltipHandler(dialog_->database_browse);
+ setTooltipHandler(dialog_->database);
+ setTooltipHandler(dialog_->style_browse);
+ setTooltipHandler(dialog_->style);
+ setTooltipHandler(dialog_->radio_bibtotoc);
}
}
}
+ if (ob == dialog_->choice_help) {
+ setTooltipLevel(dialog_->choice_help);
+ return ButtonPolicy::SMI_NOOP;
+ }
+
if (!compare(fl_get_input(dialog_->database),"")) {
return ButtonPolicy::SMI_NOOP;
}
}
-string const FormBibtex::getVerboseTooltip(FL_OBJECT * ob) const
+string const FormBibtex::getMinimalTooltip(FL_OBJECT const * ob) const
+{
+ string str;
+
+ if (ob == dialog_->database) {
+ str = N_("The BibTeX Database");
+
+ } else if (ob == dialog_->database_browse) {
+ str = _("Browse for BibTeX databases.");
+
+ } else if (ob == dialog_->style) {
+ str = _("The BibTeX style to use");
+
+ } else if (ob == dialog_->style_browse) {
+ str = _("Browse for BibTeX stylefiles.");
+
+ } else if (ob == dialog_->radio_bibtotoc) {
+ str = _("Bibliography to Table of Contents");
+ }
+
+ return str;
+}
+
+string const FormBibtex::getVerboseTooltip(FL_OBJECT const * ob) const
{
string str;
/// Filter the inputs on callback from xforms
virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
/// tooltips
- string const getVerboseTooltip(FL_OBJECT *) const;
+ string const getVerboseTooltip(FL_OBJECT const *) const;
+ ///
+ string const getMinimalTooltip(FL_OBJECT const *) const;
/// Fdesign generated method
FD_form_bibtex * build_bibtex();
fl_set_button(dialog_->button_search_case, 0);
fl_set_button(dialog_->button_search_type, 0);
+ // the help choice
+ fillTooltipChoice(dialog_->choice_help);
// Manage the ok, apply, restore and cancel/close buttons
bc().setOK(dialog_->button_ok);
bc().addReadOnly(dialog_->button_full_author_list);
bc().addReadOnly(dialog_->button_force_uppercase);
- //set up the feedback mechanism
- setPrehandler(dialog_->button_add);
- setPrehandler(dialog_->button_del);
- setPrehandler(dialog_->button_up);
- setPrehandler(dialog_->button_down);
- setPrehandler(dialog_->browser_cite);
- setPrehandler(dialog_->browser_bib);
- setPrehandler(dialog_->browser_info);
- setPrehandler(dialog_->choice_style);
- setPrehandler(dialog_->input_before);
- setPrehandler(dialog_->input_after);
- setPrehandler(dialog_->button_full_author_list);
- setPrehandler(dialog_->button_force_uppercase);
- setPrehandler(dialog_->input_search);
- setPrehandler(dialog_->button_search_case);
- setPrehandler(dialog_->button_search_type);
-
//set up the tooltip mechanism
setTooltipHandler(dialog_->button_add);
setTooltipHandler(dialog_->button_del);
activate = ButtonPolicy::SMI_VALID;
}
+ if (ob == dialog_->choice_help) {
+ setTooltipLevel(dialog_->choice_help);
+ return ButtonPolicy::SMI_NOOP;
+ }
+
string currentCitekey;
if (!citekeys.empty())
currentCitekey = citekeys[0];
}
-string const FormCitation::getMinimalTooltip(FL_OBJECT * ob) const
+string const FormCitation::getMinimalTooltip(FL_OBJECT const * ob) const
{
string str;
}
-string const FormCitation::getVerboseTooltip(FL_OBJECT * ob) const
+string const FormCitation::getVerboseTooltip(FL_OBJECT const * ob) const
{
string str;
str = N_("Activate if you want to print all authors in a reference with more than three authors, and not \"<First Author> et.al.\" (Natbib).");
} else if (ob == dialog_->button_force_uppercase) {
- str = N_("Activate if you want to print the first character of the author name as uppercase (\"Van Gogh\", not \"van Gogh\". Useful at the beginning of sentences (Natbib).");
+ str = N_("Activate if you want to print the first character of the author name as uppercase (\"Van Gogh\", not \"van Gogh\"). Useful at the beginning of sentences (Natbib).");
} else if (ob == dialog_->input_before) {
str = N_("Optional text which appears before the citation reference, e.g. \"see <Ref>\"");
/// Filter the inputs on callback from xforms
virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
/// tooltips
- string const getMinimalTooltip(FL_OBJECT *) const;
+ string const getMinimalTooltip(FL_OBJECT const *) const;
///
- string const getVerboseTooltip(FL_OBJECT *) const;
+ string const getVerboseTooltip(FL_OBJECT const *) const;
/// Fdesign generated method
FD_form_citation * build_citation();
fl_set_button(dialog_->button_fullPath, 1);
updateStyles(ControlTexinfo::cls);
- setPrehandler(dialog_->button_rescan);
- setPrehandler(dialog_->button_view);
- setPrehandler(dialog_->button_texhash);
- setPrehandler(dialog_->button_fullPath);
- setPrehandler(dialog_->browser);
- setPrehandler(dialog_->radio_cls);
- setPrehandler(dialog_->radio_sty);
- setPrehandler(dialog_->radio_bst);
- setPrehandler(dialog_->message);
+ // the help choice
+ fillTooltipChoice(dialog_->choice_help);
+ // setting up the help mechanism
setTooltipHandler(dialog_->button_rescan);
setTooltipHandler(dialog_->button_view);
setTooltipHandler(dialog_->button_texhash);
setTooltipHandler(dialog_->radio_cls);
setTooltipHandler(dialog_->radio_sty);
setTooltipHandler(dialog_->radio_bst);
- setTooltipHandler(dialog_->message);
}
ButtonPolicy::SMInput FormTexinfo::input(FL_OBJECT * ob, long) {
if (ob == dialog_->radio_cls) {
- updateStyles(ControlTexinfo::cls);
+ updateStyles(ControlTexinfo::cls);
} else if (ob == dialog_->radio_sty) {
updateStyles(ControlTexinfo::sty);
}
}
+ if (ob == dialog_->choice_help) {
+ setTooltipLevel(dialog_->choice_help);
+ return ButtonPolicy::SMI_NOOP;
+ }
+
return ButtonPolicy::SMI_VALID;
}
}
-string const FormTexinfo::getMinimalTooltip(FL_OBJECT * ob) const
+string const FormTexinfo::getMinimalTooltip(FL_OBJECT const * ob) const
{
string str;
if (ob == dialog_->radio_cls) {
- str = N_("");
+ str = N_("Available LaTeX Classes");
} else if (ob == dialog_->radio_sty) {
- str = _("");
+ str = _("Available LaTeX Styles");
} else if (ob == dialog_->radio_bst) {
- str = _("");
+ str = _("Available BibTeX Styles");
} else if (ob == dialog_->button_rescan) {
str = _("Rescan File List");
str = _("Show Full Path or not");
} else if (ob == dialog_->button_texhash) {
- str = _("");
+ str = _("Execute Script \"Texhash\"");
} else if (ob == dialog_->button_view) {
str = N_("View Content of the File");
}
-string const FormTexinfo::getVerboseTooltip(FL_OBJECT * ob) const
+string const FormTexinfo::getVerboseTooltip(FL_OBJECT const * ob) const
{
string str;
/// Filter the inputs on callback from xforms
virtual ButtonPolicy::SMInput input(FL_OBJECT *, long);
///
- string const getMinimalTooltip(FL_OBJECT *) const;
+ string const getMinimalTooltip(FL_OBJECT const *) const;
///
- string const getVerboseTooltip(FL_OBJECT *) const;
+ string const getVerboseTooltip(FL_OBJECT const *) const;
///
void updateStyles(ControlTexinfo::texFileSuffix);
/// Fdesign generated method
Timeout_pimpl.h \
Toolbar_pimpl.C \
Toolbar_pimpl.h \
+ Tooltips.C \
+ Tooltips.h \
xforms_helpers.C \
xforms_helpers.h \
xformsBC.C \
--- /dev/null
+/*
+ * \file Tooltips.C
+ * Copyright 2002 the LyX Team
+ * Read the file COPYING
+ *
+ * \author Angus Leeming, a.leeming@ic.ac.uk
+ *
+ * Tooltips for xforms. xforms 0.89 supports them directly, but 0.88 needs
+ * a bit of jiggery pokery. This class wraps it all up in a neat interface.
+ * Based on code originally in Toolbar_pimpl.C that appears to have been
+ * written by Matthias Ettrich and Jean-Marc Lasgouttes.
+ */
+
+#include <config.h>
+
+#ifdef __GNUG__
+#pragma implementation
+#endif
+
+#include "Tooltips.h"
+#include "support/LAssert.h"
+
+//#if FL_REVISION >= 89
+// Usually, this is all that is needed for xforms 0.89
+// However, I can't see an easy way to change Tooltips on the fly
+// with this method, so for now use the jiggery pokery below. ;-)
+// Angus 6 Feb 2002
+
+/*
+void Tooltips::activateTooltip(FL_OBJECT * ob)
+{
+ lyx::Assert(ob);
+
+ string const help(getTooltip(ob));
+ if (!help.empty())
+ fl_set_object_helper(ob, help.c_str());
+}
+*/
+
+//#else // if FL_REVISION < 89
+
+namespace {
+
+int TooltipHandler(FL_OBJECT *ob, int event);
+
+void TooltipTimerCB(FL_OBJECT * timer, long data);
+
+}
+
+extern "C" {
+
+static int C_TooltipHandler(FL_OBJECT * ob, int event,
+ FL_Coord, FL_Coord, int, void *)
+{
+ return TooltipHandler(ob, event);
+}
+
+
+static void C_TooltipTimerCB(FL_OBJECT * ob, long data)
+{
+ TooltipTimerCB(ob, data);
+}
+
+}
+
+
+void Tooltips::activateTooltip(FL_OBJECT * ob)
+{
+ lyx::Assert(ob);
+
+ if (!tooltip_timer_) {
+ lyx::Assert(ob->form);
+ fl_addto_form(ob->form);
+ tooltip_timer_ = fl_add_timer(FL_HIDDEN_TIMER, 0, 0, 0, 0, "");
+ fl_end_form();
+ }
+
+ fl_set_object_posthandler(ob, C_TooltipHandler);
+ ob->u_cdata = reinterpret_cast<char *>(tooltip_timer_);
+ tooltip_timer_->u_vdata = this;
+}
+
+
+namespace {
+
+void TooltipTimerCB(FL_OBJECT * timer, long data)
+{
+ FL_OBJECT * ob = reinterpret_cast<FL_OBJECT*>(data);
+ lyx::Assert(ob && ob->form && timer && timer->u_vdata);
+ FL_FORM * form = ob->form;
+ Tooltips * tooltip = static_cast<Tooltips *>(timer->u_vdata);
+
+ string const help = tooltip->getTooltip(ob);
+ if (help.empty())
+ return;
+
+ fl_show_oneliner(help.c_str(),
+ form->x + ob->x, form->y + ob->y + ob->h);
+}
+
+
+// post_handler for bubble-help (Matthias)
+int TooltipHandler(FL_OBJECT *ob, int event)
+{
+ lyx::Assert(ob);
+ FL_OBJECT * timer = reinterpret_cast<FL_OBJECT *>(ob->u_cdata);
+ lyx::Assert(timer);
+
+ // We do not test for empty help here, since this can never happen
+ if (event == FL_ENTER){
+ fl_set_object_callback(timer,
+ C_TooltipTimerCB,
+ reinterpret_cast<long>(ob));
+ fl_set_timer(timer, 1);
+ }
+ else if (event != FL_MOTION){
+ fl_set_timer(timer, 0);
+ fl_hide_oneliner();
+ }
+ return 0;
+}
+
+} // namespace anon
+
+//#endif // FL_REVISION < 89
--- /dev/null
+// -*- C++ -*-
+/*
+ * \file Tooltips.h
+ * Copyright 2002 the LyX Team
+ * Read the file COPYING
+ *
+ * \author Angus Leeming, a.leeming@ic.ac.uk
+ *
+ * Tooltips for xforms. xforms 0.89 supports them directly, but 0.88 needs
+ * a bit of jiggery pokery. This class wraps it all up in a neat interface.
+ * Based on code originally in Toolbar_pimpl.C that appears to have been
+ * written by Matthias Ettrich and Jean-Marc Lasgouttes.
+ */
+
+#ifndef TOOLTIPS_H
+#define TOOLTIPS_H
+
+#include "LString.h"
+#include <boost/utility.hpp>
+#include <sigc++/signal_system.h>
+#include FORMS_H_LOCATION // Can't forward-declare FL_OBJECT
+
+#ifdef __GNUG__
+#pragma interface
+#endif
+
+class Tooltips : boost::noncopyable {
+public:
+ /// Activate tooltips for this ob
+ void activateTooltip(FL_OBJECT * ob);
+ /** Connect this signal to the function returning the tooltip for ob
+ Eg, string FormBase::getTooltip(FL_OBJECT const *)
+ Note that SigC is unable to create a Signal1 returning string const
+ or to connect it to a const method.
+ */
+ SigC::Signal1<string, FL_OBJECT const *> getTooltip;
+
+ // We use the old method because we want to change tooltips on the fly
+//#if FL_REVISION < 89
+ ///
+ Tooltips() : tooltip_timer_(0) {}
+
+private:
+
+ FL_OBJECT * tooltip_timer_;
+//#endif
+};
+
+#endif // TOOLTIPS_H
FL_OBJECT *obj;
FD_form_bibtex *fdui = new FD_form_bibtex;
- fdui->form = fl_bgn_form(FL_NO_BOX, 450, 215);
+ fdui->form = fl_bgn_form(FL_NO_BOX, 450, 160);
fdui->form->u_vdata = this;
- obj = fl_add_box(FL_UP_BOX, 0, 0, 450, 215, "");
+ obj = fl_add_box(FL_UP_BOX, 0, 0, 450, 160, "");
{
char const * const dummy = N_("Database:|#D");
fdui->database = obj = fl_add_input(FL_NORMAL_INPUT, 90, 10, 245, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
- fdui->text_info = obj = fl_add_text(FL_NORMAL_TEXT, 10, 166, 431, 42, "");
- fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
- obj = fl_add_frame(FL_ENGRAVED_FRAME, 10, 159, 429, 1, "");
+ {
+ char const * const dummy = N_("Help:|#H");
+ fdui->choice_help = obj = fl_add_choice(FL_NORMAL_CHOICE, 89, 120, 136, 29, idex(_(dummy)));
+ fl_set_button_shortcut(obj, scex(_(dummy)), 1);
+ }
+ fl_set_object_boxtype(obj, FL_FRAME_BOX);
+ fl_set_object_callback(obj, C_FormBaseInputCB, 0);
fl_end_form();
fdui->form->fdui = fdui;
FL_OBJECT *database_browse;
FL_OBJECT *style_browse;
FL_OBJECT *radio_bibtotoc;
- FL_OBJECT *text_info;
+ FL_OBJECT *choice_help;
};
#endif /* FD_form_bibtex_h_ */
FL_OBJECT *obj;
FD_form_citation *fdui = new FD_form_citation;
- fdui->form = fl_bgn_form(FL_NO_BOX, 680, 480);
+ fdui->form = fl_bgn_form(FL_NO_BOX, 680, 440);
fdui->form->u_vdata = this;
- fdui->box = obj = fl_add_box(FL_UP_BOX, 0, 0, 680, 480, "");
+ fdui->box = obj = fl_add_box(FL_UP_BOX, 0, 0, 680, 440, "");
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
{
char const * const dummy = N_("Inset keys|#I");
fl_set_object_resize(obj, FL_RESIZE_X);
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
{
- char const * const dummy = N_("Bibliography keys|#B");
+ char const * const dummy = N_("Bibliography keys|#y");
fdui->browser_bib = obj = fl_add_browser(FL_HOLD_BROWSER, 200, 30, 160, 240, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
{
char const * const dummy = N_("Restore|#R");
- fdui->button_restore = obj = fl_add_button(FL_NORMAL_BUTTON, 10, 395, 100, 30, idex(_(dummy)));
+ fdui->button_restore = obj = fl_add_button(FL_NORMAL_BUTTON, 220, 400, 100, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_gravity(obj, FL_SouthWest, FL_SouthWest);
fl_set_object_callback(obj, C_FormBaseRestoreCB, 0);
- fdui->button_ok = obj = fl_add_button(FL_RETURN_BUTTON, 360, 395, 90, 30, _("OK"));
+ fdui->button_ok = obj = fl_add_button(FL_RETURN_BUTTON, 360, 400, 90, 30, _("OK"));
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_gravity(obj, FL_SouthEast, FL_SouthEast);
fl_set_object_callback(obj, C_FormBaseOKCB, 0);
{
char const * const dummy = N_("Apply|#A");
- fdui->button_apply = obj = fl_add_button(FL_NORMAL_BUTTON, 470, 395, 90, 30, idex(_(dummy)));
+ fdui->button_apply = obj = fl_add_button(FL_NORMAL_BUTTON, 470, 400, 90, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_callback(obj, C_FormBaseApplyCB, 0);
{
char const * const dummy = N_("Cancel|^[");
- fdui->button_cancel = obj = fl_add_button(FL_NORMAL_BUTTON, 580, 395, 90, 30, idex(_(dummy)));
+ fdui->button_cancel = obj = fl_add_button(FL_NORMAL_BUTTON, 580, 400, 90, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_gravity(obj, FL_SouthEast, FL_SouthEast);
fl_set_object_callback(obj, C_FormBaseCancelCB, 0);
- fdui->text_info = obj = fl_add_text(FL_NORMAL_TEXT, 10, 440, 660, 30, "");
- fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
- obj = fl_add_frame(FL_ENGRAVED_FRAME, 10, 430, 660, 1, "");
+ {
+ char const * const dummy = N_("Help:|#H");
+ fdui->choice_help = obj = fl_add_choice(FL_NORMAL_CHOICE, 80, 400, 130, 30, idex(_(dummy)));
+ fl_set_button_shortcut(obj, scex(_(dummy)), 1);
+ }
+ fl_set_object_boxtype(obj, FL_FRAME_BOX);
+ fl_set_object_callback(obj, C_FormBaseInputCB, 0);
fl_end_form();
fdui->form->fdui = fdui;
FL_OBJECT *button_ok;
FL_OBJECT *button_apply;
FL_OBJECT *button_cancel;
- FL_OBJECT *text_info;
+ FL_OBJECT *choice_help;
};
#endif /* FD_form_citation_h_ */
FL_OBJECT *obj;
FD_form_texinfo *fdui = new FD_form_texinfo;
- fdui->form = fl_bgn_form(FL_NO_BOX, 513, 394);
+ fdui->form = fl_bgn_form(FL_NO_BOX, 513, 353);
fdui->form->u_vdata = this;
- obj = fl_add_box(FL_UP_BOX, 0, 0, 513, 394, "");
+ obj = fl_add_box(FL_UP_BOX, 0, 0, 513, 353, "");
fl_set_object_lstyle(obj, FL_FIXED_STYLE);
fdui->browser = obj = fl_add_browser(FL_HOLD_BROWSER, 15, 12, 324, 241, "");
fl_set_object_lalign(obj, FL_ALIGN_TOP);
fl_set_object_lalign(obj, FL_ALIGN_RIGHT);
fl_set_object_gravity(obj, FL_NorthEast, FL_NorthEast);
fl_set_object_callback(obj, C_FormBaseInputCB, 2);
- fdui->message = obj = fl_add_text(FL_NORMAL_TEXT, 14, 323, 482, 56, "");
- fl_set_object_lalign(obj, FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
- fl_set_object_gravity(obj, FL_SouthWest, FL_SouthEast);
{
char const * const dummy = N_("Run Texhash|#T");
- fdui->button_texhash = obj = fl_add_button(FL_NORMAL_BUTTON, 15, 271, 135, 30, idex(_(dummy)));
+ fdui->button_texhash = obj = fl_add_button(FL_NORMAL_BUTTON, 14, 270, 131, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_callback(obj, C_FormBaseInputCB, 0);
{
char const * const dummy = N_("Close|^[^M");
- fdui->button_close = obj = fl_add_button(FL_NORMAL_BUTTON, 408, 272, 90, 30, idex(_(dummy)));
+ fdui->button_close = obj = fl_add_button(FL_NORMAL_BUTTON, 409, 313, 90, 30, idex(_(dummy)));
fl_set_button_shortcut(obj, scex(_(dummy)), 1);
}
fl_set_object_lsize(obj, FL_NORMAL_SIZE);
fl_set_object_gravity(obj, FL_SouthEast, FL_SouthEast);
fl_set_object_callback(obj, C_FormBaseCancelCB, 0);
- obj = fl_add_frame(FL_ENGRAVED_FRAME, 13, 312, 485, 1, "");
+ {
+ char const * const dummy = N_("Help:|#H");
+ fdui->choice_help = obj = fl_add_choice(FL_NORMAL_CHOICE, 344, 270, 155, 29, idex(_(dummy)));
+ fl_set_button_shortcut(obj, scex(_(dummy)), 1);
+ }
+ fl_set_object_boxtype(obj, FL_FRAME_BOX);
+ fl_set_object_callback(obj, C_FormBaseInputCB, 0);
fl_end_form();
fdui->form->fdui = fdui;
FL_OBJECT *button_rescan;
FL_OBJECT *button_view;
FL_OBJECT *button_fullPath;
- FL_OBJECT *message;
FL_OBJECT *button_texhash;
FL_OBJECT *button_close;
+ FL_OBJECT *choice_help;
};
#endif /* FD_form_texinfo_h_ */
=============== FORM ===============
Name: form_bibtex
Width: 450
-Height: 215
-Number of Objects: 10
+Height: 160
+Number of Objects: 9
--------------------
class: FL_BOX
type: UP_BOX
-box: 0 0 450 215
+box: 0 0 450 160
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
argument: 0
--------------------
-class: FL_TEXT
-type: NORMAL_TEXT
-box: 10 166 431 42
-boxtype: FL_FLAT_BOX
-colors: FL_COL1 FL_MCOL
-alignment: FL_ALIGN_LEFT|FL_ALIGN_INSIDE
-style: FL_NORMAL_STYLE
-size: FL_DEFAULT_SIZE
-lcol: FL_BLACK
-label:
-shortcut:
-resize: FL_RESIZE_ALL
-gravity: FL_NoGravity FL_NoGravity
-name: text_info
-callback:
-argument:
-
---------------------
-class: FL_FRAME
-type: ENGRAVED_FRAME
-box: 10 159 429 1
-boxtype: FL_NO_BOX
-colors: FL_BLACK FL_COL1
-alignment: FL_ALIGN_CENTER
+class: FL_CHOICE
+type: NORMAL_CHOICE
+box: 89 120 136 29
+boxtype: FL_FRAME_BOX
+colors: FL_COL1 FL_BLACK
+alignment: FL_ALIGN_LEFT
style: FL_NORMAL_STYLE
size: FL_DEFAULT_SIZE
lcol: FL_BLACK
-label:
+label: Help:|#H
shortcut:
resize: FL_RESIZE_ALL
gravity: FL_NoGravity FL_NoGravity
-name:
-callback:
-argument:
+name: choice_help
+callback: C_FormBaseInputCB
+argument: 0
==============================
create_the_forms
=============== FORM ===============
Name: form_citation
Width: 680
-Height: 480
-Number of Objects: 27
+Height: 440
+Number of Objects: 26
--------------------
class: FL_BOX
type: UP_BOX
-box: 0 0 680 480
+box: 0 0 680 440
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
style: FL_NORMAL_STYLE
size: FL_NORMAL_SIZE
lcol: FL_BLACK
-label: Bibliography keys|#B
+label: Bibliography keys|#y
shortcut:
resize: FL_RESIZE_X
gravity: FL_North FL_SouthEast
--------------------
class: FL_BUTTON
type: NORMAL_BUTTON
-box: 10 395 100 30
+box: 220 400 100 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
--------------------
class: FL_BUTTON
type: RETURN_BUTTON
-box: 360 395 90 30
+box: 360 400 90 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
--------------------
class: FL_BUTTON
type: NORMAL_BUTTON
-box: 470 395 90 30
+box: 470 400 90 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
--------------------
class: FL_BUTTON
type: NORMAL_BUTTON
-box: 580 395 90 30
+box: 580 400 90 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
argument: 0
--------------------
-class: FL_TEXT
-type: NORMAL_TEXT
-box: 10 440 660 30
-boxtype: FL_FLAT_BOX
-colors: FL_COL1 FL_MCOL
-alignment: FL_ALIGN_LEFT|FL_ALIGN_INSIDE
-style: FL_NORMAL_STYLE
-size: FL_DEFAULT_SIZE
-lcol: FL_BLACK
-label:
-shortcut:
-resize: FL_RESIZE_ALL
-gravity: FL_NoGravity FL_NoGravity
-name: text_info
-callback:
-argument:
-
---------------------
-class: FL_FRAME
-type: ENGRAVED_FRAME
-box: 10 430 660 1
-boxtype: FL_NO_BOX
-colors: FL_BLACK FL_COL1
-alignment: FL_ALIGN_CENTER
+class: FL_CHOICE
+type: NORMAL_CHOICE
+box: 80 400 130 30
+boxtype: FL_FRAME_BOX
+colors: FL_COL1 FL_BLACK
+alignment: FL_ALIGN_LEFT
style: FL_NORMAL_STYLE
size: FL_DEFAULT_SIZE
lcol: FL_BLACK
-label:
+label: Help:|#H
shortcut:
resize: FL_RESIZE_ALL
gravity: FL_NoGravity FL_NoGravity
-name:
-callback:
-argument:
+name: choice_help
+callback: C_FormBaseInputCB
+argument: 0
==============================
create_the_forms
=============== FORM ===============
Name: form_texinfo
Width: 513
-Height: 394
-Number of Objects: 14
+Height: 353
+Number of Objects: 13
--------------------
class: FL_BOX
type: UP_BOX
-box: 0 0 513 394
+box: 0 0 513 353
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
callback: C_FormBaseInputCB
argument: 2
---------------------
-class: FL_TEXT
-type: NORMAL_TEXT
-box: 14 323 482 56
-boxtype: FL_FLAT_BOX
-colors: FL_COL1 FL_MCOL
-alignment: FL_ALIGN_LEFT|FL_ALIGN_INSIDE
-style: FL_NORMAL_STYLE
-size: FL_DEFAULT_SIZE
-lcol: FL_BLACK
-label:
-shortcut:
-resize: FL_RESIZE_ALL
-gravity: FL_SouthWest FL_SouthEast
-name: message
-callback:
-argument:
-
--------------------
class: FL_BUTTON
type: NORMAL_BUTTON
-box: 15 271 135 30
+box: 14 270 131 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
--------------------
class: FL_BUTTON
type: NORMAL_BUTTON
-box: 408 272 90 30
+box: 409 313 90 30
boxtype: FL_UP_BOX
colors: FL_COL1 FL_COL1
alignment: FL_ALIGN_CENTER
argument: 0
--------------------
-class: FL_FRAME
-type: ENGRAVED_FRAME
-box: 13 312 485 1
-boxtype: FL_NO_BOX
-colors: FL_BLACK FL_COL1
-alignment: FL_ALIGN_CENTER
+class: FL_CHOICE
+type: NORMAL_CHOICE
+box: 344 270 155 29
+boxtype: FL_FRAME_BOX
+colors: FL_COL1 FL_BLACK
+alignment: FL_ALIGN_LEFT
style: FL_NORMAL_STYLE
size: FL_DEFAULT_SIZE
lcol: FL_BLACK
-label:
+label: Help:|#H
shortcut:
resize: FL_RESIZE_ALL
gravity: FL_NoGravity FL_NoGravity
-name:
-callback:
-argument:
+name: choice_help
+callback: C_FormBaseInputCB
+argument: 0
==============================
create_the_form