Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 366474 - The setText method with mnemonic char does not work with TabItem in the Windows
Summary: The setText method with mnemonic char does not work with TabItem in the Windows
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.6   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-12 21:57 EST by fahua jin CLA
Modified: 2019-11-14 03:34 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description fahua jin CLA 2011-12-12 21:57:47 EST
When the mnemonic char is included in the parameter of setText method for TabItem, I found that it cannot be displayed in the UI. Later, I found that such comments in the source code of _setText in TabItem class.

	/*
	* Bug in Windows.  In version 6.00 of COMCTL32.DLL, tab
	* items with an image and a label that includes '&' cause
	* the tab to draw incorrectly (even when doubled '&&').
	* The image overlaps the label.  The fix is to remove
	* all '&' characters from the string. 
	*/

I'm wondering if we any workaround for this defect? 

Thanks!

Rocky
Comment 1 Felipe Heidrich CLA 2011-12-14 11:23:42 EST
(In reply to comment #0)
> I'm wondering if we any workaround for this defect? 

What version of Windows are you running ?
Try removing the code that removes the '&' from the string. Is possible the bug is fixed in Windows (COMCTL32.DLL 6.01 or greater). That was the case for Bug 154904.
Comment 2 fahua jin CLA 2011-12-14 19:52:39 EST
(In reply to comment #1)
> (In reply to comment #0)
> > I'm wondering if we any workaround for this defect? 
> 
> What version of Windows are you running ?
> Try removing the code that removes the '&' from the string. Is possible the bug
> is fixed in Windows (COMCTL32.DLL 6.01 or greater). That was the case for Bug
> 154904.

My system is Windows XP + SP3, and the tester's machine is Windows 2003.

Do you mean that I need to 'hack' the code of TabItem?
Comment 3 Lars Vogel CLA 2019-11-14 03:34:24 EST
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.