Home Component Writing

Ekstra toolbar-items

edited July 2004 in Component Writing
Hi,

We are currently adding a lot of new functionality to the ReportBuilder
components and I would be great if some of the functionality could be moved
from the popup menu to the toolbar.
First: Is it possible to create new items on the toolbar?
Second: If the above is possible can you have toolbar items that only show
when specific items are selected, or alternatively disabled/enabled
depending on the selected component?

Thanks in advance
Steffen

Comments

  • edited July 2004

    Sorry, but there is currently no way to add/modify toolbars other than to
    modify the source code. Most of the Toolbar code is located in ppIDE.pas.
    There is a method in ppDsgner.pas called SetToolbarToSelection that updates
    the toolbars to reflect the current selection.

    Ideally the architecture of the Designer and Toolbars would be openly
    extensible by simple registering plug-ins. Its a matter of finding the
    resources to devote adding this capability to a future release...



    --

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited July 2004
    A follow-up question.
    Is it then possible to access the toolbars at runtime from the form that has
    the RB designer component and/or inside custom component code?

    Thanks
    Steffen


  • edited July 2004

    The TppDesigner.Form property provide access to the designer window. The
    designer window 'owns' the toolbars, so you they will be in the
    Form.Components[] array. You can use Delphi's Form.FindComponent method to
    retrieve them by name and type cast them to the appropriate type.



    --
    Nard Moseley
    Digital Metaphors Corporation
    www.digital-metaphors.com



    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.