From 7f33babf22547123cb701ae0eee4607173ff644e Mon Sep 17 00:00:00 2001 From: un1versal Date: Sat, 14 May 2016 10:32:59 +0100 Subject: OptionWidget_servers: fix indenting of newlines in toolltips source --- src/modules/options/OptionsWidget_servers.cpp | 114 +++++++++----------------- 1 file changed, 39 insertions(+), 75 deletions(-) (limited to 'src/modules/options/OptionsWidget_servers.cpp') diff --git a/src/modules/options/OptionsWidget_servers.cpp b/src/modules/options/OptionsWidget_servers.cpp index 64a96a712..61986a754 100644 --- a/src/modules/options/OptionsWidget_servers.cpp +++ b/src/modules/options/OptionsWidget_servers.cpp @@ -145,8 +145,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pUserEditor, __tr2qs_ctx("This is the username that KVIrc will use to login to servers on this network.\n" "If this field is left empty (most common case), KVIrc will use the default username " - "specified in the \"Identity\" options tab.", - "options")); + "specified in the \"Identity\" options tab.", "options")); l = new QLabel(__tr2qs_ctx("Password:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 1, 0); @@ -167,8 +166,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * pPropertiesBoxLayout->addWidget(m_pNickEditor, 2, 1); KviTalToolTip::add(m_pNickEditor, __tr2qs_ctx("You can specify a \"special\" nickname that will be used to log in to the servers on this network.
" - "If this field is left empty (most common case), the default nickname (specified in the \"Identity\" settings) will be used.", - "options")); + "If this field is left empty (most common case), the default nickname (specified in the \"Identity\" settings) will be used.", "options")); l = new QLabel(__tr2qs_ctx("Alt. nickname:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 3, 0); @@ -180,8 +178,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * pPropertiesBoxLayout->addWidget(m_pAlternativeNickEditor, 3, 1); KviTalToolTip::add(m_pAlternativeNickEditor, __tr2qs_ctx("This nickname will be tried if the primary nickname for this network is already in use.
" - "If you leave it empty then the default nicknames specified in the identity options will be tried instead.", - "options")); + "If you leave it empty then the default nicknames specified in the identity options will be tried instead.", "options")); l = new QLabel(__tr2qs_ctx("Real name:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 4, 0); @@ -191,8 +188,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * pPropertiesBoxLayout->addWidget(m_pRealEditor, 4, 1); KviTalToolTip::add(m_pRealEditor, __tr2qs_ctx("You can specify a \"special\" real name that will be used to login with the servers on this network." - "If you leave this field empty (most common case), the default \"real name\" (specified in the \"Identity\" settings) will be used.", - "options")); + "If you leave this field empty (most common case), the default \"real name\" (specified in the \"Identity\" settings) will be used.", "options")); l = new QLabel(__tr2qs_ctx("Server encoding:", "options"), tab); gl->addWidget(l, 1, 0); @@ -202,8 +198,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pEncodingEditor, __tr2qs_ctx("This box allows you to choose the preferred encoding for the servers in this network. " "This encoding will be used for server specific needs, like referencing nicknames and channel names.
" "If you choose \"Use System Encoding\" then the encoding will be set to the system-wide " - "value that you choose in the \"Encoding\" page of the options dialog.", - "options")); + "value that you choose in the \"Encoding\" page of the options dialog.", "options")); l = new QLabel(__tr2qs_ctx("Text encoding:", "options"), tab); gl->addWidget(l, 2, 0); @@ -213,8 +208,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pTextEncodingEditor, __tr2qs_ctx("This box allows you to choose the preferred encoding for the servers in this network. " "This encoding will be used as the default for text messages.
" "If you choose \"Use System Encoding\" then the encoding will be set to the system-wide " - "value that you choose in the \"Encoding\" page of the options dialog.", - "options")); + "value that you choose in the \"Encoding\" page of the options dialog.", "options")); int i = 0; int srvcurrent = 0, txtcurrent = 0; KviLocale::EncodingDescription * d = KviLocale::instance()->encodingDescription(i); @@ -262,8 +256,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pChannelListSelector, __tr2qs_ctx("Here you can set a list of channels to be joined automatically " "after a connection to a server in this network has been established. To add a channel, type its name in the " - "text input below and click \"Add\".", - "options")); + "text input below and click \"Add\".", "options")); gl->addWidget(m_pChannelListSelector, 0, 0); @@ -280,8 +273,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pOnConnectEditor, __tr2qs_ctx("The following commands will be executed after a connection to a server in this network has been established.
" "Important: Enter commands without a preceding slash (e.g. quote pass secret instead of /quote pass secret).
" "KVIrc will first send the USER command, then eventually PASS and NICK and then execute this " - "command sequence.", - "options")); + "command sequence.", "options")); tw->addTab(tab, __tr2qs_ctx("On Connect", "options")); @@ -296,8 +288,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * KviTalToolTip::add(m_pOnLoginEditor, __tr2qs_ctx("The following commands will be executed after a successful login to a server in this network.
" "Important: Enter commands without a preceding slash (e.g. quote privatelog instead of /quote privatelog).
" - "This is useful for automatically opening queries, setting variables, etc.", - "options")); + "This is useful for automatically opening queries, setting variables, etc.", "options")); tw->addTab(tab, __tr2qs_ctx("On Login", "options")); @@ -331,8 +322,7 @@ IrcNetworkDetailsWidget::IrcNetworkDetailsWidget(QWidget * par, KviIrcNetwork * "Please be aware that this feature can cause your NickServ passwords to be stolen " "if used improperly. Make sure that you fully understand the NickServ authentication protocol.
" "In other words, be sure to know what you're doing.
" - "Also note that the password that you provide is stored as PLAIN TEXT.", - "options")); + "Also note that the password that you provide is stored as PLAIN TEXT.", "options")); m_pAddRuleButton = new QPushButton(__tr2qs_ctx("Add Rule", "options"), tab); connect(m_pAddRuleButton, SIGNAL(clicked()), this, SLOT(addNickServRule())); @@ -544,8 +534,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) m_pDescEditor->setText(s->description()); KviTalToolTip::add(m_pDescEditor, __tr2qs_ctx("This is a brief description of this server. " - "This field has no restrictions but many server lists use it to describe the server's physical location", - "options")); + "This field has no restrictions but many server lists use it to describe the server's physical location", "options")); QTabWidget * tw = new QTabWidget(this); g->addWidget(tw, 2, 0, 1, 4); @@ -569,8 +558,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pUserEditor, __tr2qs_ctx("This is the username that KVIrc will use to login to this server.\n" "If this field is left empty (most common case), KVIrc will first look if a username is specified " "for the network that this server belongs to, and if that is empty then KVIrc will use the default username " - "specified in the \"Identity\" options tab.", - "options")); + "specified in the \"Identity\" options tab.", "options")); l = new QLabel(__tr2qs_ctx("Password:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 1, 0); @@ -592,8 +580,8 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pNickEditor, __tr2qs_ctx("You can specify a \"special\" nickname that will be used to log in to this server.
" "If this field is left empty (most common case), KVIrc will first look if a nickname is specified " - "for the network that this server belongs to, and if that is empty then the default nickname (specified in the \"Identity\" settings) will be used.", - "options")); + "for the network that this server belongs to, and if that is empty then the default nickname " + "(specified in the \"Identity\" settings) will be used.", "options")); l = new QLabel(__tr2qs_ctx("Alt. nickname:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 3, 0); @@ -605,8 +593,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) pPropertiesBoxLayout->addWidget(m_pAlternativeNickEditor, 3, 1); KviTalToolTip::add(m_pAlternativeNickEditor, __tr2qs_ctx("This nickname will be tried if the primary nickname for this server is already in use.
" - "If you leave it empty then the default nicknames specified in the identity options will be tried instead.", - "options")); + "If you leave it empty then the default nicknames specified in the identity options will be tried instead.", "options")); l = new QLabel(__tr2qs_ctx("Real name:", "options"), gbox); pPropertiesBoxLayout->addWidget(l, 4, 0); @@ -617,16 +604,15 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pRealEditor, __tr2qs_ctx("You can specify a \"special\" real name that will be used to login with this server.
" "If you leave this field empty (most common case), KVIrc will first look if a real name is specified " - "for the network that this server belongs to, and if that is empty the default \"real name\" (specified in the \"Identity\" settings) will be used.", - "options")); + "for the network that this server belongs to, and if that is empty the default \"real name\" " + "(specified in the \"Identity\" settings) will be used.", "options")); gbox = new KviTalGroupBox(Qt::Horizontal, __tr2qs_ctx("User Mode", "options"), tab); gl->addWidget(gbox, 1, 0); m_pUseDefaultInitUMode = new QCheckBox(__tr2qs_ctx("Use default user mode", "options"), gbox); KviTalToolTip::add(m_pUseDefaultInitUMode, __tr2qs_ctx("If this is enabled, the global initial user mode (configured from" - " the identity dialog) will be used. If disabled, you can configure an initial user mode for this server", - "options")); + " the identity dialog) will be used. If disabled, you can configure an initial user mode for this server", "options")); bool bHasUmode = !(s->initUMode().isEmpty()); KviCString szDefUMode = KVI_OPTION_STRING(KviOption_stringDefaultUserMode); @@ -677,8 +663,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pIpEditor, __tr2qs_ctx("This is the IP address of this server, it is here for caching purposes.
" "If you leave this field empty, KVIrc will fill it in the first time it connects to the server. " "If you enable the \"cache IP address\" option below, KVIrc will use it as a \"cached result\" " - "and avoid looking it up again.", - "options")); + "and avoid looking it up again.", "options")); #ifdef COMPILE_IPV6_SUPPORT m_pIpEditor->setAddressType(s->isIPv6() ? KviIpEditor::IPv6 : KviIpEditor::IPv4); #else @@ -707,8 +692,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) "this option will cause KVIrc to look up the server hostname only once.

" "Advanced: you can also use this option to force a certain server name to resolve " "to a fixed IP address when either the DNS for that server is temporarily " - "unreachable or you want to avoid the round-robin lookups.", - "options")); + "unreachable or you want to avoid the round-robin lookups.", "options")); m_pCacheIpCheck->setChecked(s->cacheIp()); @@ -730,15 +714,13 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) #endif KviTalToolTip::add(m_pUseIPV6Check, __tr2qs_ctx("This check identifies IPv6 servers.
If enabled, KVIrc will attempt to use the IPv6 protocol " - "(thus your OS must have a working IPv6 stack and you must have an IPv6 connection).", - "options")); + "(thus your OS must have a working IPv6 stack and you must have an IPv6 connection).", "options")); m_pUseSSLCheck = new QCheckBox(__tr2qs_ctx("Use SSL protocol", "options"), tab); pCheckBoxLayout->addWidget(m_pUseSSLCheck, 1, 1); KviTalToolTip::add(m_pUseSSLCheck, __tr2qs_ctx("This check will cause the connection to use the Secure Socket Layer " - "encryption support. Obviously, this server must have support for this, too. :)", - "options")); + "encryption support. Obviously, this server must have support for this, too. :)", "options")); #ifdef COMPILE_SSL_SUPPORT m_pUseSSLCheck->setChecked(s->useSSL()); connect(m_pUseSSLCheck, SIGNAL(toggled(bool)), this, SLOT(useSSLCheckToggled(bool))); @@ -756,8 +738,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pEncodingEditor, __tr2qs_ctx("This box allows you to choose the preferred encoding for this server. " "This encoding will be used for server specific needs, like referencing nicknames and channel names.
" "If you choose \"Use Network Encoding\" then the encoding will be inherited from the " - "network that this server belongs to.", - "options")); + "network that this server belongs to.", "options")); iRow++; l = new QLabel(__tr2qs_ctx("Text encoding:", "options"), tab); @@ -768,8 +749,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pTextEncodingEditor, __tr2qs_ctx("This box allows you to choose the preferred encoding for this server. " "This will be used as the default encoding for all text messages.
" "If you choose \"Use Network Encoding\" then the encoding will be inherited from the " - "network that this server belongs to.", - "options")); + "network that this server belongs to.", "options")); int i = 0; int srvcurrent = 0, txtcurrent = 0; KviLocale::EncodingDescription * d = KviLocale::instance()->encodingDescription(i); @@ -802,8 +782,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pProxyEditor, __tr2qs_ctx("Defines the connection type that KVIrc should use to connect to this server.
" "When it's set to *Default* KVIrc will use the global proxy settings, when it's set to *Direct Connection* " "KVIrc will connect directly without using a proxy, or select a desired proxy you have previously added
" - "You can define or edit new proxy servers in *General Preferences* / *Connection* tab' \"Proxy hosts\" dialog.", - "options")); + "You can define or edit new proxy servers in *General Preferences* / *Connection* tab' \"Proxy hosts\" dialog.", "options")); m_pProxyEditor->addItem(__tr2qs_ctx("Default", "options")); m_pProxyEditor->addItem(__tr2qs_ctx("Direct Connection", "options")); @@ -836,8 +815,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) m_pChannelListSelector = new KviChannelListSelector(tab, __tr2qs_ctx("Channels to Join Automatically upon Connect", "options"), &m_lstChannels, true); KviTalToolTip::add(m_pChannelListSelector, __tr2qs_ctx("Here you can set a list of channels to be joined automatically " "after a connection to this server has been established. To add a channel, type its name in the " - "text input below and click \"Add\".", - "options")); + "text input below and click \"Add\".", "options")); gl->addWidget(m_pChannelListSelector, 0, 0); @@ -853,8 +831,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pOnConnectEditor, __tr2qs_ctx("The following commands will be executed after a connection has been established.
" "Important: Enter commands without a preceding slash (e.g. quote pass secret instead of /quote pass secret).
" "KVIrc will first send the USER command, then eventually PASS and NICK and then execute this " - "command sequence.
This is particularly useful for IRC bouncers that require login commands.", - "options")); + "command sequence.
This is particularly useful for IRC bouncers that require login commands.", "options")); tw->addTab(tab, __tr2qs_ctx("On Connect", "options")); @@ -869,8 +846,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pOnLoginEditor, __tr2qs_ctx("The following commands will be executed after a successful login to this server.
" "Important: Enter commands without a preceding slash (e.g. quote privatelog instead of /quote privatelog).
" - "This is useful for automatically opening queries, setting variables, etc.", - "options")); + "This is useful for automatically opening queries, setting variables, etc.", "options")); tw->addTab(tab, __tr2qs_ctx("On Login", "options")); @@ -884,8 +860,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pEnableSTARTTLSCheck, __tr2qs_ctx("This check enables the use of the Transport Layer Security " "protocol. If you enable the Extended Capabilities below then the TLS protocol support will be detected by using " "a CAP LS command. Without \"Extended Capabilities\" the STARTTLS command will be forcibly sent at the beginning of the " - "connection.", - "options")); + "connection.", "options")); #ifndef COMPILE_SSL_SUPPORT m_pEnableSTARTTLSCheck->setEnabled(false); #endif @@ -914,8 +889,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) pSASLLayout->addWidget(m_pEnableSASLCheck, 0, 0, 1, 2); KviTalToolTip::add(m_pEnableSASLCheck, __tr2qs_ctx("This check enables the use of the SASL authentication protocol " "If you enable the proper global option in the Connection/SSL tab and fill the SASL nickname and SASL " - "password fields in this page, the SASL protocol will be used for this server if available.", - "options")); + "password fields in this page, the SASL protocol will be used for this server if available.", "options")); m_pEnableSASLCheck->setChecked(s->enabledSASL()); @@ -973,8 +947,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) m_pLinkFilterEditor->setCurrentIndex(0); KviTalToolTip::add(m_pLinkFilterEditor, __tr2qs_ctx("This field specifies the name of a module that exports a link filter for this type of server.
" - "For plain IRC connections, you don't need any link filters; this is used for incompatible protocols.", - "options")); + "For plain IRC connections, you don't need any link filters; this is used for incompatible protocols.", "options")); iRow++; @@ -988,8 +961,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) KviTalToolTip::add(m_pIdEditor, __tr2qs_ctx("This field allows you to specify a really unique ID for this server. " "You will then be able to use /server -x <this_id> to make the connection. This is especially " - "useful when you have multiple server entries with the same hostname and port in different networks (bouncers?)", - "options")); + "useful when you have multiple server entries with the same hostname and port in different networks (bouncers?)", "options")); iRow++; tw->addTab(tab, __tr2qs_ctx("Advanced", "options")); @@ -1000,8 +972,7 @@ IrcServerDetailsWidget::IrcServerDetailsWidget(QWidget * par, KviIrcServer * s) iRow = 0; l = new QLabel(__tr2qs_ctx("NickServ settings are available only for the whole IRC network, not for specific servers.\n" - "To open network settings choose a network (with a globe) in list of networks and servers and click Advanced.", - "options"), + "To open network settings choose a network (with a globe) in list of networks and servers and click Advanced.", "options"), tab); gl->addWidget(l, iRow, 0); gl->setRowStretch(1, 1); @@ -1345,8 +1316,7 @@ OptionsWidget_servers::OptionsWidget_servers(QWidget * parent) QString tiptxt = __tr2qs_ctx("This is the list of available IRC servers.
" "Right-click on the list to add or remove servers and perform other actions.
" - "Double-click on a item for advanced options.", - "options"); + "Double-click on a item for advanced options.", "options"); KviTalToolTip::add(m_pTreeWidget, tiptxt); KviTalToolTip::add(m_pTreeWidget->viewport(), tiptxt); @@ -2208,17 +2178,11 @@ IrcServerOptionsTreeWidgetItem * OptionsWidget_servers::findNetItem(const QStrin void OptionsWidget_servers::clearList() { - QString txt = "

"; - txt += __tr2qs_ctx("If you click Yes, all of your saved networks, servers, settings, and passwords will be lost.
" - "Would you like to continue?", - "options"); - txt += "

"; - - if(QMessageBox::question(this, - __tr2qs_ctx("Confirm Clearing Server List - KVIrc", "options"), txt, - __tr2qs_ctx("Yes", "options"), __tr2qs_ctx("No", "options"), nullptr, 1) - != 0) - return; + QString txt = __tr2qs_ctx("If you click Yes, all of your saved networks, servers, settings, and passwords will be lost.
" + "Would you like to continue?", "options"); + + if(QMessageBox::question(this,__tr2qs_ctx("Confirm Clearing Server List - KVIrc", "options"), txt, + __tr2qs_ctx("Yes", "options"), __tr2qs_ctx("No", "options"), nullptr, 1) != 0) return; m_pTreeWidget->clear(); m_pLastEditedItem = nullptr; -- cgit v1.3.1-10-gc9f91