Moodle
  1. Moodle
  2. MDL-13997

Wrong ancors in the links to untranslated strings

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9
    • Fix Version/s: 1.9.1, 2.0
    • Component/s: Language
    • Labels:
      None
    • Affected Branches:
      MOODLE_19_STABLE
    • Fixed Branches:
      MOODLE_19_STABLE, MOODLE_20_STABLE
    • Rank:
      30397

      Description

      In the "Language editing" on the "Check for untranslated words or phrases" tab you see all untranslated strings. After clicking on the string you see the "Edit words or phrases" page and this page is scrolled to some location inside it (say, #missing20 ancor).

      There is mistake in ancor number calculation, because of which the page is scrolled to wrong ancor.

      It's because of inconsistent numbering of ancors in these pages.

      The first page "Check for untranslated words or phrases" counts all untranslated string in main language file <language>_utf8, despite of whether it has been translated in local translation <language>_utf8_local.

      The second page "Edit words or phrases" has ancors only for strings which are untranslated both in the main and in the local language file.

      Solution. Either 1) dont make links for lines with "// translated only in _local" in the "Check for untranslated words or phrases" page, or 2) make ancors for strings with only local translation in the "Edit words or phrases" page.

        Activity

        Hide
        David Mudrak added a comment -

        Fixed in CVS in both MOODLE_19_STABLE and HEAD. Please test and report regressions. Thanks to Igor for perfect spotting and the report.

        Show
        David Mudrak added a comment - Fixed in CVS in both MOODLE_19_STABLE and HEAD. Please test and report regressions. Thanks to Igor for perfect spotting and the report.
        Hide
        Helen Foster added a comment -

        Tested in 1.9 - working perfectly! Thanks David

        Show
        Helen Foster added a comment - Tested in 1.9 - working perfectly! Thanks David
        Hide
        Igor Plisco added a comment -

        Thank you, David.

        I tried new version in translation work. It appeared to be less convenient than previous one. I made bulk translation of large files (into Russian). In the previous version I have seen the number of strings waiting for translation at the top of the page - now I must to scroll the window to look for lines with red background to look for untranslated strings. Then, in the previous version I pressed Tab to go to next untranslated (red) string. Now Tab jumps over both untranslated and locally translated strings. It's very, very less convenient than before.

        Is it possible to rollback to previous behaviour of translation page? Please. Maybe, make the page of translation checking to count only strings which are absent in local translation and not standard translation?

        Show
        Igor Plisco added a comment - Thank you, David. I tried new version in translation work. It appeared to be less convenient than previous one. I made bulk translation of large files (into Russian). In the previous version I have seen the number of strings waiting for translation at the top of the page - now I must to scroll the window to look for lines with red background to look for untranslated strings. Then, in the previous version I pressed Tab to go to next untranslated (red) string. Now Tab jumps over both untranslated and locally translated strings. It's very, very less convenient than before. Is it possible to rollback to previous behaviour of translation page? Please. Maybe, make the page of translation checking to count only strings which are absent in local translation and not standard translation?
        Hide
        David Mudrak added a comment -

        Tab key should jump through all strings that the translator should be aware of. It means both missing strings and different strings as well. This way, one can try to merge local modification into the standard pack, check if a different translation is really needed etc. IMHO this is a feature, not a bug.

        Regarding the string "Missing strings:" at the top of the page: yes, you are right. I am going to create a subtask to track this.

        Show
        David Mudrak added a comment - Tab key should jump through all strings that the translator should be aware of. It means both missing strings and different strings as well. This way, one can try to merge local modification into the standard pack, check if a different translation is really needed etc. IMHO this is a feature, not a bug. Regarding the string "Missing strings:" at the top of the page: yes, you are right. I am going to create a subtask to track this.
        Hide
        David Mudrak added a comment -

        I have just committed another fix into both HEAD and STABLE. Links from "missing" to "compare" mode are being created using ID instead of A NAME now so there should be no issues with mismatched missing counters and both pages may work separately. Also, GUI does not highlight strings translated in _local only.

        Show
        David Mudrak added a comment - I have just committed another fix into both HEAD and STABLE. Links from "missing" to "compare" mode are being created using ID instead of A NAME now so there should be no issues with mismatched missing counters and both pages may work separately. Also, GUI does not highlight strings translated in _local only.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: