Commit c7d3ef91 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt, use more tooltips, to improve accessibility

Tried to re-use already existing strings, as far as possible
parent 8ab50103
...@@ -58,7 +58,7 @@ static void Close( vlc_object_t * ); ...@@ -58,7 +58,7 @@ static void Close( vlc_object_t * );
#define PAGE_LONGTEXT N_("Open the indicated Teletext page." \ #define PAGE_LONGTEXT N_("Open the indicated Teletext page." \
"Default page is index 100") "Default page is index 100")
#define OPAQUE_TEXT N_("Text is always opaque") #define OPAQUE_TEXT N_("Teletext transparency")
#define OPAQUE_LONGTEXT N_("Setting vbi-opaque to false " \ #define OPAQUE_LONGTEXT N_("Setting vbi-opaque to false " \
"makes the boxed text transparent." ) "makes the boxed text transparent." )
......
...@@ -69,8 +69,9 @@ SPrefsCatList::SPrefsCatList( intf_thread_t *_p_intf, QWidget *_parent, bool sma ...@@ -69,8 +69,9 @@ SPrefsCatList::SPrefsCatList( intf_thread_t *_p_intf, QWidget *_parent, bool sma
#define ADD_CATEGORY( button, label, icon, numb ) \ #define ADD_CATEGORY( button, label, icon, numb ) \
QToolButton * button = new QToolButton( this ); \ QToolButton * button = new QToolButton( this ); \
button->setIcon( QIcon( ":/prefsmenu/" #icon ) ); \ button->setIcon( QIcon( ":/prefsmenu/" #icon ) ); \
button->setText( label ); \ button->setText( label ); \
button->setToolTip( label + qtr("Preferences") ); \
button->setToolButtonStyle( Qt::ToolButtonTextUnderIcon ); \ button->setToolButtonStyle( Qt::ToolButtonTextUnderIcon ); \
button->setIconSize( QSize( icon_height, icon_height ) ); \ button->setIconSize( QSize( icon_height, icon_height ) ); \
button->resize( icon_height + 6 , icon_height + 6 ); \ button->resize( icon_height + 6 , icon_height + 6 ); \
......
...@@ -67,6 +67,7 @@ SoutDialog::SoutDialog( QWidget *parent, intf_thread_t *_p_intf, const QString& ...@@ -67,6 +67,7 @@ SoutDialog::SoutDialog( QWidget *parent, intf_thread_t *_p_intf, const QString&
closeTabButton->hide(); closeTabButton->hide();
closeTabButton->setAutoRaise( true ); closeTabButton->setAutoRaise( true );
closeTabButton->setIcon( QIcon( ":/toolbar/clear" ) ); closeTabButton->setIcon( QIcon( ":/toolbar/clear" ) );
closeTabButton->setToolTip( qtr("Clear") );
BUTTONACT( closeTabButton, closeTab() ); BUTTONACT( closeTabButton, closeTab() );
#endif #endif
CONNECT( ui.destTab, currentChanged( int ), this, tabChanged( int ) ); CONNECT( ui.destTab, currentChanged( int ), this, tabChanged( int ) );
......
...@@ -152,6 +152,7 @@ ToolbarEditDialog::ToolbarEditDialog( QWidget *_w, intf_thread_t *_p_intf) ...@@ -152,6 +152,7 @@ ToolbarEditDialog::ToolbarEditDialog( QWidget *_w, intf_thread_t *_p_intf)
QToolButton *newButton = new QToolButton; QToolButton *newButton = new QToolButton;
newButton->setIcon( QIcon( ":/new" ) ); newButton->setIcon( QIcon( ":/new" ) );
newButton->setToolTip( qtr("New profile") );
QToolButton *deleteButton = new QToolButton; QToolButton *deleteButton = new QToolButton;
deleteButton->setIcon( QIcon( ":/toolbar/clear" ) ); deleteButton->setIcon( QIcon( ":/toolbar/clear" ) );
deleteButton->setToolTip( qtr( "Delete the current profile" ) ); deleteButton->setToolTip( qtr( "Delete the current profile" ) );
...@@ -376,14 +377,17 @@ WidgetListing::WidgetListing( intf_thread_t *p_intf, QWidget *_parent ) ...@@ -376,14 +377,17 @@ WidgetListing::WidgetListing( intf_thread_t *p_intf, QWidget *_parent )
QToolButton *prevSectionButton = new QToolButton( discFrame ); QToolButton *prevSectionButton = new QToolButton( discFrame );
prevSectionButton->setIcon( QIcon( ":/toolbar/dvd_prev" ) ); prevSectionButton->setIcon( QIcon( ":/toolbar/dvd_prev" ) );
prevSectionButton->setToolTip( qtr("Previous chapter") );
discLayout->addWidget( prevSectionButton ); discLayout->addWidget( prevSectionButton );
QToolButton *menuButton = new QToolButton( discFrame ); QToolButton *menuButton = new QToolButton( discFrame );
menuButton->setIcon( QIcon( ":/toolbar/dvd_menu" ) ); menuButton->setIcon( QIcon( ":/toolbar/dvd_menu" ) );
menuButton->setToolTip( qtr("Go to the DVD menu") );
discLayout->addWidget( menuButton ); discLayout->addWidget( menuButton );
QToolButton *nextButton = new QToolButton( discFrame ); QToolButton *nextButton = new QToolButton( discFrame );
nextButton->setIcon( QIcon( ":/toolbar/dvd_next" ) ); nextButton->setIcon( QIcon( ":/toolbar/dvd_next" ) );
nextButton->setToolTip( qtr("Next chapter") );
discLayout->addWidget( nextButton ); discLayout->addWidget( nextButton );
widget = discFrame; widget = discFrame;
...@@ -401,7 +405,8 @@ WidgetListing::WidgetListing( intf_thread_t *p_intf, QWidget *_parent ) ...@@ -401,7 +405,8 @@ WidgetListing::WidgetListing( intf_thread_t *p_intf, QWidget *_parent )
telexLayout->addWidget( telexOn ); telexLayout->addWidget( telexOn );
QToolButton *telexTransparent = new QToolButton; QToolButton *telexTransparent = new QToolButton;
telexOn->setIcon( QIcon( ":/toolbar/tvtelx" ) ); telexTransparent->setIcon( QIcon( ":/toolbar/tvtelx" ) );
telexTransparent->setToolTip( qtr("Teletext transparency") );
telexLayout->addWidget( telexTransparent ); telexLayout->addWidget( telexTransparent );
QSpinBox *telexPage = new QSpinBox; QSpinBox *telexPage = new QSpinBox;
......
...@@ -499,10 +499,12 @@ VLMAWidget::VLMAWidget( const QString& _name, const QString& _input, ...@@ -499,10 +499,12 @@ VLMAWidget::VLMAWidget( const QString& _name, const QString& _input,
QToolButton *modifyButton = new QToolButton; QToolButton *modifyButton = new QToolButton;
modifyButton->setIcon( QIcon( ":/menu/settings" ) ); modifyButton->setIcon( QIcon( ":/menu/settings" ) );
modifyButton->setToolTip( qtr("Change") );
objLayout->addWidget( modifyButton, 0, 5 ); objLayout->addWidget( modifyButton, 0, 5 );
QToolButton *deleteButton = new QToolButton; QToolButton *deleteButton = new QToolButton;
deleteButton->setIcon( QIcon( ":/menu/quit" ) ); deleteButton->setIcon( QIcon( ":/menu/quit" ) );
deleteButton->setToolTip("Delete");
objLayout->addWidget( deleteButton, 0, 6 ); objLayout->addWidget( deleteButton, 0, 6 );
BUTTONACT( modifyButton, modify() ); BUTTONACT( modifyButton, modify() );
...@@ -541,14 +543,17 @@ VLMBroadcast::VLMBroadcast( const QString& _name, const QString& _input, ...@@ -541,14 +543,17 @@ VLMBroadcast::VLMBroadcast( const QString& _name, const QString& _input,
playButton = new QToolButton; playButton = new QToolButton;
playButton->setIcon( QIcon( ":/menu/play" ) ); playButton->setIcon( QIcon( ":/menu/play" ) );
playButton->setToolTip( qtr("Play") );
objLayout->addWidget( playButton, 1, 0 ); objLayout->addWidget( playButton, 1, 0 );
b_playing = true; b_playing = true;
QToolButton *stopButton = new QToolButton; QToolButton *stopButton = new QToolButton;
stopButton->setIcon( QIcon( ":/toolbar/stop_b" ) ); stopButton->setIcon( QIcon( ":/toolbar/stop_b" ) );
stopButton->setToolTip( qtr("Stop") );
objLayout->addWidget( stopButton, 1, 1 ); objLayout->addWidget( stopButton, 1, 1 );
loopButton = new QToolButton; loopButton = new QToolButton;
loopButton->setToolTip( qtr("Repeat") );
objLayout->addWidget( loopButton, 1, 2 ); objLayout->addWidget( loopButton, 1, 2 );
BUTTONACT( playButton, togglePlayPause() ); BUTTONACT( playButton, togglePlayPause() );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment