Files
odoo-stubs/odoo-stubs/tools/translate.pyi
Trinh Anh Ngoc 73a1a2b9f1 Cleanup
2023-05-19 22:06:03 +07:00

91 lines
2.2 KiB
Python

import csv
from typing import Any
WEB_TRANSLATION_COMMENT: str
SKIPPED_ELEMENTS: Any
ENGLISH_SMALL_WORDS: Any
class UNIX_LINE_TERMINATOR(csv.excel):
lineterminator: str
def encode(s): ...
TRANSLATED_ELEMENTS: Any
TRANSLATED_ATTRS: Any
avoid_pattern: Any
class XMLTranslator:
callback: Any
method: Any
parser: Any
needs_trans: bool
def __init__(self, callback, method, parser: Any | None = ...) -> None: ...
def todo(self, text, needs_trans: bool = ...) -> None: ...
def all_todo(self): ...
def get_todo(self): ...
def flush(self) -> None: ...
def done(self, text) -> None: ...
def get_done(self): ...
def process_text(self, text): ...
def process_attr(self, attr): ...
def process(self, node) -> None: ...
def serialize(self, tag, attrib, content): ...
def xml_translate(callback, value): ...
def html_translate(callback, value): ...
def translate(cr, name, source_type, lang, source: Any | None = ...): ...
class GettextAlias:
def __call__(self, source): ...
_: Any
def quote(s): ...
re_escaped_char: Any
re_escaped_replacements: Any
def unquote(str): ...
class PoFile:
buffer: Any
def __init__(self, buffer) -> None: ...
lines: Any
lines_count: Any
first: bool
extra_lines: Any
def __iter__(self): ...
def cur_line(self): ...
def next(self): ...
def write_infos(self, modules): ...
def write(
self, modules, tnrs, source, trad, comments: Any | None = ...
) -> None: ...
def trans_export(lang, modules, buffer, format, cr) -> None: ...
def trans_parse_rml(de): ...
def in_modules(object_name, modules): ...
def babel_extract_qweb(fileobj, keywords, comment_tags, options): ...
def trans_generate(lang, modules, cr): ...
def trans_load(
cr,
filename,
lang,
verbose: bool = ...,
module_name: Any | None = ...,
context: Any | None = ...,
): ...
def trans_load_data(
cr,
fileobj,
fileformat,
lang,
lang_name: Any | None = ...,
verbose: bool = ...,
module_name: Any | None = ...,
context: Any | None = ...,
) -> None: ...
def get_locales(lang: Any | None = ...) -> None: ...
def resetlocale(): ...
def load_language(cr, lang) -> None: ...