Set tooltips JideTabbedPane Buttons

This is the forum for JIDE Common Layer which is open sourced at https://github.com/jidesoft/jide-oss. Please note, JIDE technical support doesn't monitor this forum as often as other forums. Please consider subscribe for technical support for JIDE Common Layer so that you can use customer only forum to get a timely response.

Moderator: JIDE Support

Forum rules
Community driven forum for open source JIDE Common Layer. JIDE technical support doesn't monitor this forum as often as other forums. If you only use JIDE Common Layer, please consider subscribing for technical support for JIDE Common Layer so that you can use customer only forum to get a timely response.

Set tooltips JideTabbedPane Buttons

Postby eramirezj » Thu Jul 05, 2012 3:27 pm

I need to customize the tooltips of the buttons that are created in a JideTabbedPane component, specifically
these components are setShowTabButtons(true) unique and only visible do, thanks.

View to buttons is:

http://s2.subirimagenes.com/otros/previo/thump_7821404duda.jpg

Image
eramirezj
 
Posts: 12
Joined: Mon Jan 02, 2012 6:43 am

Re: Set tooltips JideTabbedPane Buttons

Postby JIDE Support » Thu Jul 05, 2012 4:31 pm

Please override JideTabbedPane#getResourceString() to customize the tool tips. The relevant resource keys are showed as following code fraction.
Code: Select all
       JideTabbedPane tabbedPane = new JideTabbedPane(JideTabbedPane.TOP){
            @Override
            public String getResourceString(String key) {
                if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_SCROLL_BACKWARD)){
                    return "backward";
                }
                else if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_SCROLL_FORWARD)){
                    return "forward";
                }
                else if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_TAB_LIST)){
                    return "list";
                }
                return super.getResourceString(key);    //To change body of overridden methods use File | Settings | File Templates.
            }
        };


Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am

Re: Set tooltips JideTabbedPane Buttons

Postby eramirezj » Fri Jul 06, 2012 8:52 am

eramirezj wrote:I need to customize the tooltips of the buttons that are created in a JideTabbedPane component, specifically
these components are setShowTabButtons(true) unique and only visible do, thanks.

View to buttons is:

http://s2.subirimagenes.com/otros/previo/thump_7821404duda.jpg

Image
JIDE Support wrote:Please override JideTabbedPane#getResourceString() to customize the tool tips. The relevant resource keys are showed as following code fraction.
Code: Select all
       JideTabbedPane tabbedPane = new JideTabbedPane(JideTabbedPane.TOP){
            @Override
            public String getResourceString(String key) {
                if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_SCROLL_BACKWARD)){
                    return "backward";
                }
                else if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_SCROLL_FORWARD)){
                    return "forward";
                }
                else if (key != null && key.equals(BasicJideTabbedPaneUI.BUTTON_NAME_TAB_LIST)){
                    return "list";
                }
                return super.getResourceString(key);    //To change body of overridden methods use File | Settings | File Templates.
            }
        };


Thanks,


Thanks for your help, greetings :wink:
eramirezj
 
Posts: 12
Joined: Mon Jan 02, 2012 6:43 am

Re: Set tooltips JideTabbedPane Buttons

Postby poshoklo » Fri Mar 01, 2013 2:39 pm

Hi!
And how do you change the look and feel of the first three buttons (scroll backward, scroll forward and close)?

Thanks for your help in advance!
poshoklo
 
Posts: 1
Joined: Fri Mar 01, 2013 2:38 pm

Re: Set tooltips JideTabbedPane Buttons

Postby JIDE Support » Fri Mar 01, 2013 3:19 pm

Those three buttons are painted by drawing directly so I don't think they will change in different L&F.

Thanks,
JIDE Software Technical Support Team
JIDE Support
Site Admin
 
Posts: 37219
Joined: Sun Sep 14, 2003 10:49 am


Return to JIDE Common Layer Open Source Project Discussion (Community Driven)

Who is online

Users browsing this forum: Google [Bot] and 11 guests

cron