komorra / NodeEditorWinforms

Node based user control / editor for Windows Forms
MIT License
507 stars 142 forks source link

Node Width #12

Closed kiranmaya closed 3 years ago

kiranmaya commented 4 years ago

How to Set node Width ?

kiranmaya commented 4 years ago

can you give an example of custom editor for nodes

komorra commented 3 years ago

How to Set node Width ?

Feature of a custom node with and height was added from commit d889db48aa2a26f2642b40285351f05988e885e2 (24 Jan 2021). Now it can be used for example:

[Node("IsPrime",isCallable:false, width:250)]
public void IsPrime(int number, out bool result)
{
    result = true;
    for (int i = 2; i < Math.Sqrt(number)+1; i++)
    {
        if(number % i == 0)
        {
            result = false;
        }
    }
}
kiranmaya commented 3 years ago

Thanks for the feature.