Edwin Leuven <[EMAIL PROTECTED]> writes:

Don't forget to add liconview.[Ch] to Makefile.am too:
> Index: development/scons/SConscript
> ===================================================================
> --- development/scons/SConscript      (revision 13913)
> +++ development/scons/SConscript      (working copy)
>  <at>  <at>  -816,6 +816,7  <at>  <at> 
>      floatplacement.C
>      iconpalette.C
>      lengthcombo.C
> +     liconview.C
>      panelstack.C
>      QAboutDialog.C
>      QBibitemDialog.C

> Index: src/frontends/qt4/liconview.h

No doxygen comments:
> +class LIconView : public QTableWidget {
> +  ...
> +};
> +
> +} // namespace frontend
> +} // namespace lyx
> +
> +#endif // LICONVIEW_H

> Index: src/frontends/qt4/QLAction.h
The "const" in "bool const foo" isn't needed/wanted in the header, only in the
.C file. Think of it as an implementation detail.
No doxygen comments. What does the updateonly do?
While you're at it, it should be "std::string const & tooltip = std::string()".

>       QLAction(LyXView & lyxView, std::string const & text,
> -             FuncRequest const & func, std::string const & tooltip="");
> +             FuncRequest const & func, std::string const & tooltip="", bool 
> const
updateonly_ = false);

> Index: src/frontends/qt4/QLToolbar.C
Urgggsss. This kind of hard coding is really nasty. The info should go in the
.ui files somehow.

> -             QLAction * action = new QLAction(owner_, 
> toolbarbackend.getIcon(func), "",
func, tooltip);
> -             toolbar_->addAction(action);
> -             ActionVector.push_back(action);
> -
> +             if (func.action==LFUN_TABULAR_INSERT) {
> +                     QLAction * action = new QLAction(owner_, 
> toolbarbackend.getIcon(func), "",
func, tooltip, true);
> +                     QToolButton * tb = new QToolButton;
> +                     LIconView * iv = new LIconView(tb, owner_, func);
> +                     connect(action, SIGNAL(triggered()), iv, SLOT(show()));
> +                     tb->setDefaultAction(action);
> +                     toolbar_->addWidget(tb);
> +                     ActionVector.push_back(action);
> +             } else {
> +                     QLAction * action = new QLAction(owner_, 
> toolbarbackend.getIcon(func), "",
func, tooltip);
> +                     toolbar_->addAction(action);
> +                     ActionVector.push_back(action);
> +             }
>               break;

Regards,
Angus

Reply via email to