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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Statusbar Panel Width

Thread ID:

Created:

Updated:

Platform:

Replies:

40850 Feb 15,2006 09:10 AM UTC Feb 21,2006 05:30 AM UTC Windows Forms 2
loading
Tags: Tools
Christian Rattat
Asked On February 15, 2006 09:10 AM UTC

Hi, we use SF Suite 3.0.1.0 and I discovered a problem with the statusbar. Using german locale the date and time panels size to correct width. Using other locale (e.g. en-US) the panels do not resize to show the entire content. Even if I use size to content mode the width is too small. How can I make date/time panels always fit the content or (as workaround) is there any chance to add some fixed additional width to these panels (in size to content mode)? Thanks in advance, Christian

Anupama Roy [Syncfusion]
Replied On February 20, 2006 10:48 AM UTC

Hi Christian, Sorry for the delay in response. I was not able to reproduce the above mentioned problem with our latest version.However, in your version,if the size to content mode is not working appropriately,please include the below given code snippet and call this function in the Form Load event. private void RecalculateSize() { int width = 0; Graphics g = CreateGraphics(); g.TextRenderingHint = System.Drawing.Text.TextRenderingHint.AntiAliasGridFit; width += g.MeasureString(this.statusBarAdvPanel1.GetText(),Font).ToSize().Width; this.statusBarAdvPanel1.ClientSize = new Size(width,this.statusBarAdvPanel1.Bounds.Height); g.Dispose(); } Please let me know if you have any questions. Thanks for your interest in Syncfusion products. Regards, Anu.

Christian Rattat
Replied On February 21, 2006 05:30 AM UTC

Hi Anu, thanks for the hints. I have the same problem even in your original statusbar demo shipped with 3.0.1.0. However I changed the sizing mode to autosize=false and then used the measuring you suggested. Now it works as I want. Thanks! regards, Christian > >Hi Christian, > >Sorry for the delay in response. > >I was not able to reproduce the above mentioned problem with our latest version.However, in your version,if the size to content mode is not working appropriately,please include the below given code snippet and call this function in the Form Load event. > >private void RecalculateSize() > { > > int width = 0; > Graphics g = CreateGraphics(); > g.TextRenderingHint = System.Drawing.Text.TextRenderingHint.AntiAliasGridFit; > width += g.MeasureString(this.statusBarAdvPanel1.GetText(),Font).ToSize().Width; > this.statusBarAdvPanel1.ClientSize = new Size(width,this.statusBarAdvPanel1.Bounds.Height); > g.Dispose(); > } > >Please let me know if you have any questions. > >Thanks for your interest in Syncfusion products. > >Regards, > >Anu.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;