Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #243516: Untranslated strings, from Qt #3272

Merged
merged 2 commits into from
Aug 14, 2017

Conversation

Jojo-Schmitz
Copy link
Contributor

@Jojo-Schmitz Jojo-Schmitz commented Aug 10, 2017

  • Remove all Qt translations from the MuseScore repository that are also part of Qt, and deploy their's instead.
  • Also, as a side effect, deploy our Bulgarian translation for Qt (seems a day one ommision), not needed with Qt-5.9.1 anymore though, could get deleted once we switch to that. It doesn't harm though, as it'll get overwritten if available in Qt
  • Simplify the whole process for adding languages and running lupdate
  • Add Kabyle language, shows how easy this becomes with those simplifications (see also https://github.com/musescore/tx2s3/pull/4)

Should be good for master and 2.2

Not really sure the CMakeLists.txt change works for Linux and Mac (I tested this only for Windows), but judging from https://travis-ci.org/musescore/MuseScore/jobs/263144588#L4246-L4346 it seems to work just fine for Linux

DESTINATION ${Mscore_SHARE_NAME}${Mscore_INSTALL_NAME}locale
FILES_MATCHING
REGEX ".*\\.qm"
REGEX "qt_blank\\.qm" EXCLUDE
Copy link
Contributor Author

@Jojo-Schmitz Jojo-Schmitz Aug 10, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could probably removed too, just need to find out why it does get generated in the first place, regardless not being mentioned in build/gen-qt-projectfile or build/gen-qt-projectfile.bat.

Hmm, seems it gets generated by lrelease, from https://github.com/musescore/MuseScore/blob/master/CMakeLists.txt#L660, but lupdate is never run on it and it doesn't really serve any purpose, so we'd better remove it, esp. as we now should no longer need this as a template for yet unsupported languages

@@ -64,42 +64,17 @@ echo " $1/share/locale/mscore_uz@Latn.ts \\"
echo " $1/share/locale/mscore_vi.ts \\"
echo " $1/share/locale/mscore_zh_CN.ts \\"
echo " $1/share/locale/mscore_zh_TW.ts \\"
echo " $1/share/locale/qt_ar.ts \\"
echo " $1/share/locale/qt_bg.ts \\"
Copy link
Contributor Author

@Jojo-Schmitz Jojo-Schmitz Aug 10, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bulgarian not needed as of Qt-5.9.1, but doesn't harm either, it'll get overwritten if available in Qt.
But I wonder whether this script can get rewritten and simplified using wildcards rather then a list of files.
Same for build/gen-qt-projectfile.bat

@Jojo-Schmitz Jojo-Schmitz force-pushed the qt-translations branch 2 times, most recently from 0d1d8b4 to 1fc876e Compare August 10, 2017 16:58
REGEX ".*\\.qm")

if (MINGW)
install(DIRECTORY ${CROSSQT}/translations/
Copy link
Contributor Author

@Jojo-Schmitz Jojo-Schmitz Aug 10, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess together with #3213 and/or #3215, we can simplify this further, and reduce it to the content of the else branch.

@Jojo-Schmitz Jojo-Schmitz force-pushed the qt-translations branch 2 times, most recently from e7a8031 to 4ad3d59 Compare August 11, 2017 07:38
Remove all Qt translations from the MuseScore repository
that are also part of Qt 5.4 and later, and deploy Qt's instead.
Also , as a side effect, deploy our Bulgarian translation for Qt
(seems a day one ommision and not needed for Qt-5.9.1 and later)

Simplify the whole process for adding languages and running lupdate

Should be good for master and 2.2
@Jojo-Schmitz Jojo-Schmitz force-pushed the qt-translations branch 2 times, most recently from 63763ce to 41b7906 Compare August 13, 2017 18:53
@lasconic lasconic merged commit 69c376f into musescore:master Aug 14, 2017
@Jojo-Schmitz Jojo-Schmitz deleted the qt-translations branch August 14, 2017 15:44
@Jojo-Schmitz
Copy link
Contributor Author

Still needs https://github.com/musescore/tx2s3/pull/4 for "Update translations" to show Kabyle.
And I'm pretty sure we'd want this for 2.2 too (yes, I know, that patience thing again ;-)).

echo " $1/share/locale/qt_uk.ts \\"
echo " $1/share/locale/qt_vi.ts \\"
echo " $1/share/locale/qt_zh_CN.ts \\"
echo " $1/share/locale/qt_zh_TW.tsTW.ts"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Funny, another bug fixed in the passing

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

less code, less bug.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true. I just wonder why this went unnoticed

@@ -114,5 +19,8 @@ uis=`find $1 -name "*.cpp"`
for a in $uis; do
echo " " $a \\;
done
uis=`find $1/share/instruments -name "*.h"`
for a in $uis; do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done is missing here

mscore_vi.qm
mscore_zh_CN.qm
mscore_zh_TW.qm
languages.xml
Copy link
Contributor Author

@Jojo-Schmitz Jojo-Schmitz Aug 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tada! here's another problem, we still need languages.xml. See #3278

@@ -37,6 +37,7 @@
<language code="it" name="Italiano" />
<language code="ja" name="日本語" />
<language code="ka" name="ქართული" />
<language code="kab" name="ⵜⴰⵇⴱⴰⵢⵍⵉⵜ" />
Copy link
Contributor Author

@Jojo-Schmitz Jojo-Schmitz Aug 15, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another issue: this string doesn't display in MuseScore's languages selection dialog, not on Windows 7 and 10 at least. It does show when opening that file with IE11 (Windows 10 also with Edge), as does in QtCreator and GitHub for Windows.
Might be some font issue on Windows, with MuseScore's default menu font?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On Windows, I believe MuseScore menu fonts is the default windows font. I don't see this string here on mac on github.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would probably be better to use one of the transliteration https://en.wikipedia.org/wiki/Kabyle_language There is only one string translated on transifex but it "looks" a bit like "Tamaziɣt Taqbaylit"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's go for just "Taqbaylit", see also https://de.wikipedia.org/wiki/Kabylische_Sprache

Jojo-Schmitz added a commit to Jojo-Schmitz/MuseScore that referenced this pull request Sep 15, 2017
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts all all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)
Jojo-Schmitz added a commit to Jojo-Schmitz/MuseScore that referenced this pull request Sep 15, 2017
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)
lasconic pushed a commit that referenced this pull request Sep 19, 2017
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR #3272 , 41b7906 (master) and d1b606e (2.2)
lasconic pushed a commit that referenced this pull request Sep 19, 2017
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR #3272 , 41b7906 (master) and d1b606e (2.2)
rjmatthews62 pushed a commit to rjmatthews62/MuseScore that referenced this pull request Sep 23, 2017
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)
rjmatthews62 pushed a commit to rjmatthews62/MuseScore that referenced this pull request Sep 26, 2017
…template

more frets for steel and 12 string guitars

and adjust professional
range to match the possible max. frets

Fix #213391: add G clarinet and Lupophone, extend ranges of oboe, contra* clarinets and contrabass

update harmony layout

fix for auto layout lyrics/slurs

Fix lupdate step to not put all translations into all ts files

but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)

try new Qt::AA_EnableHighDpiScaling app attribute

try new Qt::AA_EnableHighDpiScaling app attribute again

Implemented TimeSig wrapper so random.qml would work.

Modified timesig help

* Improved support for MuseScore 3.0 plugins
* Added a "set" to ElementW for setting properties.
* Added a buildWrapper static function to allow different wrapper descendants.
* Converted "random.qml" to work with MuseScore 3.0
* Added a TimeSigW class to support added features required to manipulate TimeSig
* Added support for lists of valid property names for use with "get" and "set"

Implemented TimeSig wrapper so random.qml would work.

Modified timesig help

colornotes.qml now works with Musescore 3.0

* Improved support for MuseScore 3.0 plugins
* Added a "set" to ElementW for setting properties.
* Added a buildWrapper static function to allow different wrapper descendants.
* Converted "random.qml" to work with MuseScore 3.0
* Added a TimeSigW class to support added features required to manipulate TimeSig
* Added support for lists of valid property names for use with "get" and "set"
* Modified timesig help
colornotes.qml and random.qml now works with Musescore 3.0
Added proplist.qml to demonstrate readProperties and writeProperties

Formatting and Indenting tidy up.

Sorted out cursor.element()  call, fixed elementWrapper linking.

Tidied up tests, incorporated previous mods to colornotes.qml, code indenting and formatting.
rjmatthews62 pushed a commit to rjmatthews62/MuseScore that referenced this pull request Sep 26, 2017
…template

more frets for steel and 12 string guitars

and adjust professional
range to match the possible max. frets

Fix #213391: add G clarinet and Lupophone, extend ranges of oboe, contra* clarinets and contrabass

update harmony layout

fix for auto layout lyrics/slurs

Fix lupdate step to not put all translations into all ts files

but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)

try new Qt::AA_EnableHighDpiScaling app attribute

try new Qt::AA_EnableHighDpiScaling app attribute again

Implemented TimeSig wrapper so random.qml would work.

Modified timesig help

* Improved support for MuseScore 3.0 plugins
* Added a "set" to ElementW for setting properties.
* Added a buildWrapper static function to allow different wrapper descendants.
* Converted "random.qml" to work with MuseScore 3.0
* Added a TimeSigW class to support added features required to manipulate TimeSig
* Added support for lists of valid property names for use with "get" and "set"

Implemented TimeSig wrapper so random.qml would work.

Modified timesig help

colornotes.qml now works with Musescore 3.0

* Improved support for MuseScore 3.0 plugins
* Added a "set" to ElementW for setting properties.
* Added a buildWrapper static function to allow different wrapper descendants.
* Converted "random.qml" to work with MuseScore 3.0
* Added a TimeSigW class to support added features required to manipulate TimeSig
* Added support for lists of valid property names for use with "get" and "set"
* Modified timesig help
colornotes.qml and random.qml now works with Musescore 3.0
Added proplist.qml to demonstrate readProperties and writeProperties

Formatting and Indenting tidy up.

Sorted out cursor.element()  call, fixed elementWrapper linking.

Tidied up tests, incorporated previous mods to colornotes.qml, code indenting and formatting.
blackears pushed a commit to blackears/MuseScore that referenced this pull request Jul 4, 2018
but put mscore translations into mscore_*.ts only, instruments
translations into instruments_*.ts only and don't run lupdate against
qt*.ts at all.
The latter seems to have been done wrongly since quite a while, the
former since PR musescore#3272 , 41b7906 (master) and d1b606e (2.2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants