We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Sizing of Diagram Editor Window

Hi Nagaraj,
The diagram editor window looks some thing like a A4 sheet with scroll bars. How do I set the maximum width of the window. It does not happen even if I select Dock Style to Fill.

Thanks & Regards,
RKP

1 Reply

J. J.Nagarajan Syncfusion Team July 25, 2007 09:47 PM UTC

Hi Krishna,

Sorry for the inconvenience caused, This is default behavior of the diagram model. Because in our source code we have positioned the diagram model as A4 sheet style type. Please refer to the following code snippet in our source code.

private void ResetScrollPosition()
{
MeasureUnits docUnits = this.Model.MeasurementUnits;

// get model size
int nWidth = (int)Math.Round( MeasureUnitsConverter.ToPixelX( this.Model.Size.Width, docUnits ) );
int nHeight =(int)Math.Round( MeasureUnitsConverter.ToPixelX( this.Model.Size.Height/2, docUnits ) );

// update virtual bounds
m_rcVirtualBounds.Location = new PointF( -nWidth, -nHeight );
m_rcVirtualBounds.Size = new SizeF( nWidth, nHeight );

//update scroll min and max value
UpdateScrollRange();
// reset origin referance to update scroll value
this.ptScrollOriginRef = new PointF( this.Origin.X - 1, 0 );
// update scroll position to origin
UpdateScrolls( this.Origin );
}

We could not change this behavior in an application level. Please let me know if you have any questions.

Thanks,
Nagaraj

Loader.
Live Chat Icon For mobile
Up arrow icon