Improve string formatting and context
Improves some strings according to the KDE HIG, and specifies whether they are titles, buttons, or tooltips.
This commit is contained in:
parent
215b0790fd
commit
108b6759f7
@ -154,9 +154,9 @@ getWidgetSidebar( Calamares::DebugWindowManager* debug,
|
||||
aboutDialog->setIcon( Calamares::defaultPixmap(
|
||||
Calamares::Information, Calamares::Original, 2 * QSize( defaultFontHeight, defaultFontHeight ) ) );
|
||||
CALAMARES_RETRANSLATE_FOR(
|
||||
aboutDialog, aboutDialog->setText( QCoreApplication::translate( "calamares-sidebar", "About" ) );
|
||||
aboutDialog, aboutDialog->setText( QCoreApplication::translate( "calamares-sidebar", "About", "@button" ) );
|
||||
aboutDialog->setToolTip(
|
||||
QCoreApplication::translate( "calamares-sidebar", "Show information about Calamares" ) ); );
|
||||
QCoreApplication::translate( "calamares-sidebar", "Show information about Calamares", "@tooltip" ) ); );
|
||||
extraButtons->addWidget( aboutDialog );
|
||||
aboutDialog->setFlat( true );
|
||||
aboutDialog->setCheckable( true );
|
||||
@ -169,9 +169,9 @@ getWidgetSidebar( Calamares::DebugWindowManager* debug,
|
||||
debugWindowBtn->setIcon( Calamares::defaultPixmap(
|
||||
Calamares::Bugs, Calamares::Original, 2 * QSize( defaultFontHeight, defaultFontHeight ) ) );
|
||||
CALAMARES_RETRANSLATE_FOR(
|
||||
debugWindowBtn, debugWindowBtn->setText( QCoreApplication::translate( "calamares-sidebar", "Debug" ) );
|
||||
debugWindowBtn, debugWindowBtn->setText( QCoreApplication::translate( "calamares-sidebar", "Debug", "@button" ) );
|
||||
debugWindowBtn->setToolTip(
|
||||
QCoreApplication::translate( "calamares-sidebar", "Show debug information" ) ); );
|
||||
QCoreApplication::translate( "calamares-sidebar", "Show debug information", "@tooltip" ) ); );
|
||||
extraButtons->addWidget( debugWindowBtn );
|
||||
debugWindowBtn->setFlat( true );
|
||||
debugWindowBtn->setCheckable( true );
|
||||
@ -199,7 +199,7 @@ getWidgetNavigation( Calamares::DebugWindowManager*,
|
||||
{
|
||||
auto* back
|
||||
= new QPushButton( getButtonIcon( QStringLiteral( "go-previous" ) ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Back" ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Back", "@button" ),
|
||||
navigation );
|
||||
back->setObjectName( "view-button-back" );
|
||||
back->setEnabled( viewManager->backEnabled() );
|
||||
@ -215,7 +215,7 @@ getWidgetNavigation( Calamares::DebugWindowManager*,
|
||||
{
|
||||
auto* next
|
||||
= new QPushButton( getButtonIcon( QStringLiteral( "go-next" ) ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Next" ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Next", "@button" ),
|
||||
navigation );
|
||||
next->setObjectName( "view-button-next" );
|
||||
next->setEnabled( viewManager->nextEnabled() );
|
||||
@ -232,7 +232,7 @@ getWidgetNavigation( Calamares::DebugWindowManager*,
|
||||
{
|
||||
auto* quit
|
||||
= new QPushButton( getButtonIcon( QStringLiteral( "dialog-cancel" ) ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Cancel" ),
|
||||
QCoreApplication::translate( CalamaresWindow::staticMetaObject.className(), "&Cancel", "@button" ),
|
||||
navigation );
|
||||
quit->setObjectName( "view-button-cancel" );
|
||||
QObject::connect( quit, &QPushButton::clicked, viewManager, &Calamares::ViewManager::quit );
|
||||
@ -398,6 +398,7 @@ CalamaresWindow::CalamaresWindow( QWidget* parent )
|
||||
setWindowFlag( Qt::WindowCloseButtonHint, false );
|
||||
}
|
||||
|
||||
// %1 is the distribution name
|
||||
CALAMARES_RETRANSLATE( const auto* branding = Calamares::Branding::instance();
|
||||
setWindowTitle( Calamares::Settings::instance()->isSetupMode()
|
||||
? tr( "%1 Setup Program" ).arg( branding->productName() )
|
||||
|
@ -161,7 +161,7 @@ DebugWindow::DebugWindow()
|
||||
m_ui->sendLogButton->setVisible( Calamares::Paste::isEnabled() );
|
||||
connect( m_ui->sendLogButton, &QPushButton::clicked, [ this ]() { Calamares::Paste::doLogUploadUI( this ); } );
|
||||
|
||||
CALAMARES_RETRANSLATE( m_ui->retranslateUi( this ); setWindowTitle( tr( "Debug information" ) ); );
|
||||
CALAMARES_RETRANSLATE( m_ui->retranslateUi( this ); setWindowTitle( tr( "Debug Information", "@title" ) ); );
|
||||
}
|
||||
|
||||
void
|
||||
@ -232,8 +232,8 @@ void
|
||||
DebugWindowManager::about()
|
||||
{
|
||||
QString title = Calamares::Settings::instance()->isSetupMode()
|
||||
? QCoreApplication::translate( "WelcomePage", "About %1 setup" )
|
||||
: QCoreApplication::translate( "WelcomePage", "About %1 installer" );
|
||||
? QCoreApplication::translate( "WelcomePage", "About %1 Setup", "@title" )
|
||||
: QCoreApplication::translate( "WelcomePage", "About %1 Installer", "@title" );
|
||||
QMessageBox mb( QMessageBox::Information,
|
||||
title.arg( CALAMARES_APPLICATION_NAME ),
|
||||
Calamares::aboutString().arg( Calamares::Branding::instance()->versionedName() ),
|
||||
|
@ -99,7 +99,7 @@ SPDX-License-Identifier: GPL-3.0-or-later
|
||||
<item>
|
||||
<widget class="QPushButton" name="crashButton">
|
||||
<property name="toolTip">
|
||||
<string>Crashes Calamares, so that Dr. Konqui can look at it.</string>
|
||||
<string>Crashes Calamares, so that Dr. Konqi can look at it.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string notr="true">Crash now</string>
|
||||
|
Loading…
Reference in New Issue
Block a user