X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fbe%2Fnikiroo%2Ffanfix%2Fbundles%2FStringId.java;h=97722484f15a605dbb481e4defb3be5248a156c6;hb=HEAD;hp=39cb0b239f4d9df67c276881e0efa2fe433efff7;hpb=08fe2e33007063e30fe22dc1d290f8afaa18eb1d;p=fanfix.git diff --git a/src/be/nikiroo/fanfix/bundles/StringId.java b/src/be/nikiroo/fanfix/bundles/StringId.java index 39cb0b2..9772248 100644 --- a/src/be/nikiroo/fanfix/bundles/StringId.java +++ b/src/be/nikiroo/fanfix/bundles/StringId.java @@ -3,8 +3,8 @@ package be.nikiroo.fanfix.bundles; import java.io.IOException; import java.io.Writer; +import be.nikiroo.utils.resources.Bundle; import be.nikiroo.utils.resources.Meta; -import be.nikiroo.utils.resources.bundles.Bundle; /** * The {@link Enum} representing textual information to be translated to the @@ -15,6 +15,7 @@ import be.nikiroo.utils.resources.bundles.Bundle; * * @author niki */ +@SuppressWarnings("javadoc") public enum StringId { /** * A special key used for technical reasons only, without annotations so it @@ -30,69 +31,97 @@ public enum StringId { * Use it when you need a real translation but still don't have a key. */ DUMMY, // - @Meta(what = "error message", where = "cli", format = "%s = supported input, %s = supported output", info = "syntax error message") + @Meta(info = "%s = supported input, %s = supported output", description = "help message for the syntax") + HELP_SYNTAX, // + @Meta(description = "syntax error message") ERR_SYNTAX, // - @Meta(what = "error message", where = "cli", format = "%s = support name, %s = support desc", info = "an input or output support type description") + @Meta(info = "%s = support name, %s = support desc", description = "an input or output support type description") ERR_SYNTAX_TYPE, // - @Meta(what = "error message", where = "cli", format = "%s = input string", info = "Error when retrieving data") + @Meta(info = "%s = input string", description = "Error when retrieving data") ERR_LOADING, // - @Meta(what = "error message", where = "cli", format = "%s = save target", info = "Error when saving to given target") + @Meta(info = "%s = save target", description = "Error when saving to given target") ERR_SAVING, // - @Meta(what = "error message", where = "cli", format = "%s = bad output format", info = "Error when unknown output format") + @Meta(info = "%s = bad output format", description = "Error when unknown output format") ERR_BAD_OUTPUT_TYPE, // - @Meta(what = "error message", where = "cli", format = "%s = input string", info = "Error when converting input to URL/File") + @Meta(info = "%s = input string", description = "Error when converting input to URL/File") ERR_BAD_URL, // - @Meta(what = "error message", where = "cli", format = "%s = input url", info = "URL/File not supported") + @Meta(info = "%s = input url", description = "URL/File not supported") ERR_NOT_SUPPORTED, // - @Meta(what = "error message", where = "BasicSupport", format = "%s = cover URL", info = "Failed to download cover : %s") + @Meta(info = "%s = cover URL", description = "Failed to download cover : %s") ERR_BS_NO_COVER, // - @Meta(what = "char", where = "LaTeX/BasicSupport", format = "single char", info = "Canonical OPEN SINGLE QUOTE char (for instance: `)") + @Meta(def = "`", info = "single char", description = "Canonical OPEN SINGLE QUOTE char (for instance: ‘)") OPEN_SINGLE_QUOTE, // - @Meta(what = "char", where = "LaTeX/BasicSupport", format = "single char", info = "Canonical CLOSE SINGLE QUOTE char (for instance: ‘)") + @Meta(def = "‘", info = "single char", description = "Canonical CLOSE SINGLE QUOTE char (for instance: ’)") CLOSE_SINGLE_QUOTE, // - @Meta(what = "char", where = "LaTeX/BasicSupport", format = "single char", info = "Canonical OPEN DOUBLE QUOTE char (for instance: “)") + @Meta(def = "“", info = "single char", description = "Canonical OPEN DOUBLE QUOTE char (for instance: “)") OPEN_DOUBLE_QUOTE, // - @Meta(what = "char", where = "LaTeX/BasicSupport", format = "single char", info = "Canonical CLOSE DOUBLE QUOTE char (for instance: ”)") + @Meta(def = "”", info = "single char", description = "Canonical CLOSE DOUBLE QUOTE char (for instance: ”)") CLOSE_DOUBLE_QUOTE, // - @Meta(what = "chapter name", where = "BasicSupport", format = "", info = "Name of the description fake chapter") + @Meta(def = "Description", description = "Name of the description fake chapter") DESCRIPTION, // - @Meta(what = "chapter name", where = "", format = "%d = number, %s = name", info = "Name of a chapter with a name") + @Meta(def = "Chapter %d: %s", info = "%d = number, %s = name", description = "Name of a chapter with a name") CHAPTER_NAMED, // - @Meta(what = "chapter name", where = "", format = "%d = number, %s = name", info = "Name of a chapter without name") + @Meta(def = "Chapter %d", info = "%d = number, %s = name", description = "Name of a chapter without name") CHAPTER_UNNAMED, // - @Meta(what = "input format description", where = "SupportType", format = "%s = type", info = "Default description when the type is not known by i18n") + @Meta(info = "%s = type", description = "Default description when the type is not known by i18n") INPUT_DESC, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_EPUB, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_TEXT, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_INFO_TEXT, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_FANFICTION, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_FIMFICTION, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_MANGAFOX, // - @Meta(what = "input format description", where = "SupportType", format = "", info = "Description of this input type") + @Meta(description = "Description of this input type") INPUT_DESC_E621, // - @Meta(what = "output format description", where = "OutputType", format = "%s = type", info = "Default description when the type is not known by i18n") + @Meta(description = "Description of this input type") + INPUT_DESC_E_HENTAI, // + @Meta(description = "Description of this input type") + INPUT_DESC_YIFFSTAR, // + @Meta(description = "Description of this input type") + INPUT_DESC_CBZ, // + @Meta(description = "Description of this input type") + INPUT_DESC_HTML, // + @Meta(info = "%s = type", description = "Default description when the type is not known by i18n") OUTPUT_DESC, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") OUTPUT_DESC_EPUB, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") OUTPUT_DESC_TEXT, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") OUTPUT_DESC_INFO_TEXT, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") OUTPUT_DESC_CBZ, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") + OUTPUT_DESC_HTML, // + @Meta(description = "Description of this output type") OUTPUT_DESC_LATEX, // - @Meta(what = "output format description", where = "OutputType", format = "", info = "Description of this output type") + @Meta(description = "Description of this output type") OUTPUT_DESC_SYSOUT, // - @Meta(what = "error message", where = "LaTeX", format = "%s = the unknown 2-code language", info = "Error message for unknown 2-letter LaTeX language code") + @Meta(group = true, info = "%s = type", description = "Default description when the type is not known by i18n") + OUTPUT_DESC_SHORT, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_EPUB, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_TEXT, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_INFO_TEXT, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_CBZ, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_LATEX, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_SYSOUT, // + @Meta(description = "Short description of this output type") + OUTPUT_DESC_SHORT_HTML, // + @Meta(info = "%s = the unknown 2-code language", description = "Error message for unknown 2-letter LaTeX language code") LATEX_LANG_UNKNOWN, // - @Meta(what = "'by' prefix before author name", where = "", format = "", info = "used to output the author, make sure it is covered by Config.BYS for input detection") + @Meta(def = "by", description = "'by' prefix before author name used to output the author, make sure it is covered by Config.BYS for input detection") BY, // ; @@ -119,4 +148,4 @@ public enum StringId { writer.write("# Also, the comments always refer to the key below them.\n"); writer.write("# \n"); } -}; +}