Rename a palette

Hi,

How can I rename a palette? From Symbol Designer? I can't find the option, could you help me?

Thanks!


1 Reply

AA Amsath Ali M Syncfusion Team July 4, 2012 05:49 AM UTC

Hi Blanca,

 

Thanks for your interest in Syncfusion products.

 

We suggest you to use the PaletteGroupBar’s ‘InplaceRenameItem’ method, ‘GroupBarItemRenamed’ event to rename a paletteGroupbar in symbol designer application.

We have modified the Symbol designer application to achieve your requirement and the same can be downloaded from the below link:

Note: Please right click the groupbar header and select ‘RenameItem’ option from the context menu in order to rename the paletteGroupBar.

 

Here is the code:

[C#]

 

  symbolPaletteGroupBar.ShowContextMenu += new EventHandler(symbolPaletteGroupBar_ShowContextMenu);

            symbolPaletteGroupBar.GroupBarItemRenamed += new GroupItemRenamedEventHandler(symbolPaletteGroupBar_GroupBarItemRenamed);

 

void symbolPaletteGroupBar_ShowContextMenu(object sender, EventArgs e)

        {

            Syncfusion.Windows.Forms.Tools.XPMenus.PopupMenu menu = new Syncfusion.Windows.Forms.Tools.XPMenus.PopupMenu();

 

            menu.ParentBarItem = new Syncfusion.Windows.Forms.Tools.XPMenus.ParentBarItem();

            menu.ParentBarItem.Style = Syncfusion.Windows.Forms.VisualStyle.Office2003;

 

            BarItem renameitem = new BarItem("Rename Item", new EventHandler(this.gvc_MenuRenameItem));

            menu.ParentBarItem.Items.Add(renameitem);

 

            menu.Show(this.symbolPaletteGroupBar, this.symbolPaletteGroupBar.PointToClient(Cursor.Position));

        }

 

        private void gvc_MenuRenameItem(object sender, EventArgs e)

        {

            this.symbolPaletteGroupBar.InplaceRenameItem(this.symbolPaletteGroupBar.ContextMenuItem);

        }

 

        void symbolPaletteGroupBar_GroupBarItemRenamed(object obj, GroupItemRenamedEventArgs arg)

        {

            symbolPaletteGroupBar.CurrentSymbolPalette.Name = arg.NewLabel;

        }

 

Here is the link to download the utilities:

[C#]

Symbol designer:

Symbol Designer.zip

 

Please replace the above modified SymbolDesigner source in the below location.


“{System Drive}\Program Files\Syncfusion\Essential Studio\10.2.0.56\Utilities\Diagram\Windows Forms\Symbol Designer\ “

Kindly take a backup of the SymbolDesigner utility before installing the new one.

 

Please let us know if you have any queries.

 

Regards,

Amsath Ali. M



Symbol Designer_51754240.zip

Loader.
Up arrow icon