A few corrections (v. 5.0)

Developer
Apr 21, 2011 at 5:48 PM
Edited Apr 21, 2011 at 6:05 PM

When a table row is selected it does not show its text or image. The solutions lies in changing/correcting the CreateSelectionBrush method in the Crainiate.Diagramming.Singleton.cs. Its contents should be

_selectionBrush = new SolidBrush ( Color.FromArgb ( 16, SelectionPen.Color ) );

 instead of 

_selectionBrush = new SolidBrush(Color.White);

When in an interactive mode other than Normal and click outside an element an exception is raises on the MouseUp event handler in the class Crainiate.Diagramming.Forms.Diagram. To solve this you have to replace the

    foreach ( Element element in ControlRender.Actions )
    {
        element.ActionElement = null;
    }
 at line 998 with 
    if ( ControlRender.Actions != null )
    {
        foreach ( Element element in ControlRender.Actions )
        {
            element.ActionElement = null;
        }
    }

When a table element loses selection, if there's a table item selected (TableRow or TableGroup) it continues selected. The solution lies in changing Crainiate.Diagramming.Forms.Rendering.TableRender.cs, at line 167, where the condition should be

if (table.DrawSelectedItem && table.Selected && table.SelectedItem != null && render is ControlRender)

 instead of

if (table.DrawSelectedItem && table.SelectedItem != null && render is ControlRender)