Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » CTabFolderRenderer can't be usefully subclassed
CTabFolderRenderer can't be usefully subclassed [message #525996] Thu, 08 April 2010 13:32 Go to next message
Simon Pope is currently offline Simon PopeFriend
Messages: 28
Registered: July 2009
Junior Member
Correct me if I'm wrong but CTabFolder in 3.6 M6 got a new Renderer
(CTabFolderRenderer) that according to the new and noteworthy:

> CTabFolder has been improved and now allows clients to change its look by implementing their own renderers.

And in the CTabFolderRenderer class header it says:

> Instances of this class provide all of the measuring and drawing functionality
> required by <code>CTabFolder</code>. This class can be subclassed in order to
> customize the look of a CTabFolder.

Which is all fine and dandy, except that CTabFolderRenderer declares ALL
of its useful member variables as having default visibility – which
means that I can't meaningfully create a subclass outside of the
org.eclipse.swt.custom package, since one wouldn't be able to access
these variables otherwise.

Is this an oversight, or part of a plan to tease us with features we
really want but can't have? – or is the mention in New and Noteworthy
for M6 somewhat premature?

Opened a bug against this:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=308472
Re: CTabFolderRenderer can't be usefully subclassed [message #525997 is a reply to message #525996] Thu, 08 April 2010 13:47 Go to previous message
Simon Pope is currently offline Simon PopeFriend
Messages: 28
Registered: July 2009
Junior Member
Presumably, the only things I can override are the drawing of each
element and computing the size.

OK, so this can be subclassed – but it's going to take some work.

On 8/04/10 11:32 PM, Simon Pope wrote:
> Correct me if I'm wrong but CTabFolder in 3.6 M6 got a new Renderer
> (CTabFolderRenderer) that according to the new and noteworthy:
>
>> CTabFolder has been improved and now allows clients to change its look
>> by implementing their own renderers.
>
> And in the CTabFolderRenderer class header it says:
>
>> Instances of this class provide all of the measuring and drawing
>> functionality
>> required by <code>CTabFolder</code>. This class can be subclassed in
>> order to
>> customize the look of a CTabFolder.
>
> Which is all fine and dandy, except that CTabFolderRenderer declares ALL
> of its useful member variables as having default visibility – which
> means that I can't meaningfully create a subclass outside of the
> org.eclipse.swt.custom package, since one wouldn't be able to access
> these variables otherwise.
>
> Is this an oversight, or part of a plan to tease us with features we
> really want but can't have? – or is the mention in New and Noteworthy
> for M6 somewhat premature?
>
> Opened a bug against this:
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=308472
>
Previous Topic:Problems with non-ascii paths in FileDialog in SWT GTK
Next Topic:SWT.PASSWORD default echo char
Goto Forum:
  


Current Time: Sun Dec 08 16:51:51 GMT 2024

Powered by FUDForum. Page generated in 0.02944 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top