Nevron Forum

Layout's configuration dialog

https://www.nevron.com/Forum/Topic7500.aspx

By Iryna Borzenko - Monday, February 25, 2013

Hello,

I am interest in the next thing. Does Nevron have a dialog window for configuration layouts objects (something like NFillStyleTypeEditor for fill style)? Nevron Diagram Designer has 'Diagram Options' dialog... Is it possible to reuse this window or such things should be implemented by hands?

Thanks in advance!
By Nevron Support - Tuesday, February 26, 2013

Hi Iryna,

You can easily add all the diagram commands you see in the Diagram Designer to your form using the following code in your form's Load event handler:

NDiagramCommandBarsManager manager = new NDiagramCommandBarsManager();

manager.View = nDrawingView1;

manager.ParentControl = this;

By Iryna Borzenko - Tuesday, February 26, 2013

Thank you, but it is match more then i need. Is it possible to use 'Diagram options' dialog apart from NDiagramCommandBarsManager (without showing toolbars)???
By Nevron Support - Wednesday, February 27, 2013

Hi,

To execute only a specific command from the command bars manager, you can use the following code:

NDiagramCommandCollection commands = manager.Commander.Commands;

NDiagramButtonCommand command = (NDiagramButtonCommand)commands.GetCommandFromId((int)DiagramCommand.ShowLayoutDialog);

command.Execute();

Please, note that you should have previously created and attached a command bars manager to the drawing view like this:

manager = new NDiagramCommandBarsManager();

manager.View = m_View;

 

In this way, when you do not set the parent of the diagram command bars manager to be the current Windows form, the menus and the toolbars will not be shown and you will get exactly the functionality you require.

By Iryna Borzenko - Sunday, March 3, 2013

Thank you! It is awesome!
By Iryna Borzenko - Thursday, March 7, 2013

I have one more question about LayoutDialog. How can I configure layouts list of this window. For example I need not DockLayout, how can i remove it from there?
By Nevron Support - Friday, March 29, 2013

You have no access to the content of the internal Nevron Diagram dialogs. If your requirements have grown to a point at which you want to modify the Layout Dialog itself it will be best to create a dialog of your own. In this way you will be able to implement exactly the features you require.