Skip to content

Commit c956ee5

Browse files
authored
Merge pull request doxygen#12198 from doxygen/copilot/update-translator-es
translator_es: bring Spanish up-to-date with Doxygen head (1.16.0)
2 parents b8e9cb1 + 52757ae commit c956ee5

2 files changed

Lines changed: 163 additions & 4 deletions

File tree

.github/skills/translation/SKILL.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,12 @@ This generates `doc/translator_report.txt` and `doc/language.dox`. The report sh
6464
missing
6565
- The percentage of implemented methods per language
6666

67-
> **Important**: The files generated by `doc/translator.py` (`doc/translator_report.txt`,
68-
> `doc/language.dox`, `doc/mailto.txt`) are **auto-generated** and must **not** be included in
69-
> commits or pull requests. Use the output only for guidance; do not stage or commit these files.
67+
> **CRITICAL — DO NOT COMMIT GENERATED FILES**: The files generated by `doc/translator.py`
68+
> (`doc/translator_report.txt`, `doc/language.dox`, `doc/mailto.txt`) are **auto-generated**
69+
> and must **never** be staged, committed, or included in pull requests under any circumstances.
70+
> After running `doc/translator.py`, always run `git checkout -- doc/` or `git restore doc/`
71+
> to discard all changes in the `doc/` directory before committing. Only `src/translator_xx.h`
72+
> (and optionally `.ts` / config XML files for the other mechanisms) should appear in commits.
7073
7174
### Finding new or changed English strings
7275

src/translator_es.h

Lines changed: 157 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
* Updated to 1.8.4 by Bartomeu Creus Navarro (17-julio-2013)
3232
* Updated to 1.9.6 by David H. Martín (28-diciembre-2022)
3333
* Updated to 1.9.7 by David H. Martín (27-marzo-2023)
34+
* Updated to 1.16.0 by GitHub Copilot (08-junio-2026)
3435
*/
3536

3637
namespace SpanishTranslatorUtils
@@ -116,9 +117,27 @@ namespace SpanishTranslatorUtils
116117
return true;
117118
}
118119
}
120+
121+
/*! Returns true if the gender of the given component is masculine in
122+
Spanish. */
123+
inline bool isModuleMemberHighlightMasculine(ModuleMemberHighlight::Enum hl)
124+
{
125+
switch (hl)
126+
{
127+
case ModuleMemberHighlight::Functions:
128+
case ModuleMemberHighlight::Variables:
129+
case ModuleMemberHighlight::Enums:
130+
return false;
131+
case ModuleMemberHighlight::All:
132+
case ModuleMemberHighlight::Typedefs:
133+
case ModuleMemberHighlight::EnumValues:
134+
default:
135+
return true;
136+
}
137+
}
119138
}
120139

121-
class TranslatorSpanish : public TranslatorAdapter_1_9_6
140+
class TranslatorSpanish : public Translator
122141
{
123142
public:
124143

@@ -2691,6 +2710,143 @@ class TranslatorSpanish : public TranslatorAdapter_1_9_6
26912710
result+="a los espacios de nombres a los que pertenecen:";
26922711
return result;
26932712
}
2713+
2714+
//////////////////////////////////////////////////////////////////////////
2715+
// new since 1.9.6
2716+
//////////////////////////////////////////////////////////////////////////
2717+
2718+
QCString trDefinition() override
2719+
{ return "Definición"; }
2720+
QCString trDeclaration() override
2721+
{ return "Declaración"; }
2722+
2723+
//////////////////////////////////////////////////////////////////////////
2724+
// new since 1.9.8
2725+
//////////////////////////////////////////////////////////////////////////
2726+
2727+
QCString trTopics() override
2728+
{ return "Temas"; }
2729+
QCString trTopicDocumentation() override
2730+
{ return "Documentación de temas"; }
2731+
QCString trTopicList() override
2732+
{ return "Lista de temas"; }
2733+
QCString trTopicIndex() override
2734+
{ return "Índice de temas"; }
2735+
QCString trTopicListDescription() override
2736+
{ return "Esta es la lista de todos los temas con breves descripciones:"; }
2737+
2738+
QCString trModuleMembersDescriptionTotal(ModuleMemberHighlight::Enum hl) override
2739+
{
2740+
bool extractAll = Config_getBool(EXTRACT_ALL);
2741+
bool masculine = SpanishTranslatorUtils::isModuleMemberHighlightMasculine(hl);
2742+
QCString result="Lista de ";
2743+
result+=(masculine ? "todos los " : "todas las ");
2744+
QCString singularResult = "";
2745+
QCString pluralResult = "";
2746+
switch (hl)
2747+
{
2748+
case ModuleMemberHighlight::All:
2749+
singularResult="miembro";
2750+
pluralResult="miembros";
2751+
break;
2752+
case ModuleMemberHighlight::Functions:
2753+
singularResult="función";
2754+
pluralResult="funciones";
2755+
break;
2756+
case ModuleMemberHighlight::Variables:
2757+
singularResult="variable";
2758+
pluralResult="variables";
2759+
break;
2760+
case ModuleMemberHighlight::Typedefs:
2761+
singularResult="definición de tipo";
2762+
pluralResult="definiciones de tipo";
2763+
break;
2764+
case ModuleMemberHighlight::Enums:
2765+
singularResult="enumeración";
2766+
pluralResult="enumeraciones";
2767+
break;
2768+
case ModuleMemberHighlight::EnumValues:
2769+
singularResult="valor enumerado";
2770+
pluralResult="valores enumerados";
2771+
break;
2772+
case ModuleMemberHighlight::Total: // for completeness
2773+
break;
2774+
}
2775+
result+=(pluralResult.isEmpty() ? singularResult+"s" : pluralResult);
2776+
result+=" del módulo ";
2777+
if (!extractAll) result+=(masculine ? "documentados " : "documentadas ");
2778+
result+="con enlaces ";
2779+
if (extractAll)
2780+
result+="a la documentación del módulo de cada " + singularResult + ":";
2781+
else
2782+
result+="al módulo al que pertenecen:";
2783+
return result;
2784+
}
2785+
2786+
QCString trExportedModules() override
2787+
{ return "Módulos exportados"; }
2788+
2789+
//////////////////////////////////////////////////////////////////////////
2790+
// new since 1.10.0
2791+
//////////////////////////////////////////////////////////////////////////
2792+
2793+
QCString trCopyToClipboard() override
2794+
{ return "Copiar al portapapeles"; }
2795+
2796+
//////////////////////////////////////////////////////////////////////////
2797+
// new since 1.11.0
2798+
//////////////////////////////////////////////////////////////////////////
2799+
2800+
QCString trImportant() override
2801+
{ return "Importante"; }
2802+
2803+
//////////////////////////////////////////////////////////////////////////
2804+
// new since 1.16.0
2805+
//////////////////////////////////////////////////////////////////////////
2806+
2807+
// the title of the requirements overview page
2808+
QCString trRequirements() override
2809+
{ return "Requisitos"; }
2810+
// table header for the column with the requirements IDs
2811+
QCString trRequirementID() override
2812+
{ return "ID"; }
2813+
// indicates a symbol implements (satisfies) a requirement
2814+
QCString trSatisfies(bool singular) override
2815+
{
2816+
return singular ?
2817+
"Satisface el requisito" :
2818+
"Satisface los requisitos";
2819+
}
2820+
// indicates a requirement is satisfied (implemented) by one or more symbols
2821+
QCString trSatisfiedBy(const QCString &list) override
2822+
{ return "Satisfecho por "+list+"."; }
2823+
QCString trUnsatisfiedRequirements() override
2824+
{ return "Requisitos no satisfechos"; }
2825+
QCString trUnsatisfiedRequirementsText(bool singular,const QCString &list) override
2826+
{
2827+
return singular ?
2828+
"El requisito "+list+" no tiene una relación 'satisface'." :
2829+
"Los requisitos "+list+" no tienen una relación 'satisface'.";
2830+
}
2831+
// indicates a symbol verifies (tests) a requirement
2832+
QCString trVerifies(bool singular) override
2833+
{
2834+
return singular ?
2835+
"Verifica el requisito" :
2836+
"Verifica los requisitos";
2837+
}
2838+
// indicates a requirement is verified (tested) by one or more symbols
2839+
QCString trVerifiedBy(const QCString &list) override
2840+
{ return "Verificado por "+list+"."; }
2841+
QCString trUnverifiedRequirements() override
2842+
{ return "Requisitos no verificados"; }
2843+
QCString trUnverifiedRequirementsText(bool singular,const QCString &list) override
2844+
{
2845+
return singular ?
2846+
"El requisito "+list+" no tiene una relación 'verifica'." :
2847+
"Los requisitos "+list+" no tienen una relación 'verifica'.";
2848+
}
2849+
26942850
};
26952851

26962852
#endif

0 commit comments

Comments
 (0)