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. (Last updated on : November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Setting the size of the MDITab text area

Thread ID:

Created:

Updated:

Platform:

Replies:

17303 Aug 5,2004 12:11 PM UTC Aug 9,2004 04:15 PM UTC WinForms 3
loading
Tags: Tools
Derek Stafford
Asked On August 5, 2004 12:11 PM UTC

How can I restrict the size of the text area for MDI tab text. I want to achieve the same effect as in Visual Studio where long names are dotted and the tooltip provides the full name. For example, I want the tab text to display: "My Docum...\fred.txt" whereas the full text value is actually: "My Documents\fred.txt"

Administrator [Syncfusion]
Replied On August 5, 2004 05:24 PM UTC

Hi, Please note that in VS.Net only the docking windows arranged in a tabbed group display this behavior and not the MDI Tabs. Refer to the screenshot attached that illustrates this. Our docking windows and tabbedMDI frameworks are closely modelled on the VS.Net''s frameworks and hence we have maintained similar behavior for consistency purposes. Please let us know if you have any suggestions in this regard. We appreciate your interest in Syncfusion products. Regards, Guru Patwal Syncfusion, Inc.

Derek Stafford
Replied On August 6, 2004 10:26 AM UTC

Hmm. Well the MDI tabs in my Visual Studio seem to have this behaviour (see attached screenshot). Clip1_1838.zip

Administrator [Syncfusion]
Replied On August 9, 2004 04:15 PM UTC

Hi Horeslover, Thanks for the screenshot. I could observe such a behavior in the VS.Net''s MDI tabs which were created by transforming a docking window into MDI child form (by unchecking Dockable in the docking window''s context-menu). Such a feature is not supported directly in the TabbedMDI framework since the text formatting behavior is contextual, i.e., the number of dots that have to be placed in between so as to create meaningful text on the MDI tabs. You could try the following workaround : Implement the ITabbedMDIChildForm interface in each of the MDI child forms public class MdiChildForm : System.Windows.Forms.Form, ITabbedMDIChildForm { : : : public void OnAttachTabbedMDI(TabbedMDIManager manager) { } public void OnDetachTabbedMDI(TabbedMDIManager manager) { } public void OnTabContextMenuPopup(ParentBarItem contextMenuParentItem) { } public void OnTabContextMenuClosed(ParentBarItem contextMenuParentItem) { } public bool AllowUserDrag { get { return true; } } public void OnMdiChildAddedToTabHost(TabHost tabHost, int tabIndex) { } public string GetCustomTabText(out bool validValueReturned) { string str; validValueReturned = true; // Check the text length and set the desired short form if (this.Text.Length > 25) str = ""C:\\...\\Essential Suite"; else str = "C:\\Program Files\\Essential Suite"; return str; } } Please let me know if this meets your requirements. We appreciate your interest in Syncfusion products. Regards, Guru Patwal Syncfusion, Inc.

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

;