summaryrefslogtreecommitdiffstats
path: root/tools/linguist/shared
Commit message (Collapse)AuthorAgeFilesLines
* optimization: avoid creating unnecessary temporariesOswald Buddenhagen2011-06-011-35/+29
| | | | | erase messages instead of building a new list of non-dropped ones. modify messages instead of replacing them with modified copies.
* add hash-based indexing to Translator for fast find()Oswald Buddenhagen2011-06-012-26/+92
|
* remove Translator::translatedMessages()Oswald Buddenhagen2011-06-013-13/+1
| | | | | it's inefficient to construct a new list. on top of that, the only user actually checks the message state again.
* remove Translator::contains()Oswald Buddenhagen2011-06-012-9/+0
| | | | it's redundant with find() now, as the latter is cheap now
* optimization: make the Translator::find() api index-basedOswald Buddenhagen2011-06-012-10/+11
|
* nuke Translator::release(), make saveQM() non-static insteadOswald Buddenhagen2011-06-013-12/+3
| | | | this "factory" served only to obfuscate the code
* synchronize qmake project parser with qt creatorOswald Buddenhagen2011-06-0112-2556/+4589
| | | | | qt creator as of ddb918f. not feeling like replaying the whole history ...
* Update licenseheader text in source files for qt4.8Jyri Tahtela2011-05-1318-306/+306
| | | | | | | Updated version of LGPL and FDL licenseheaders. Apply release phase licenseheaders for all source files. Reviewed-by: Trust Me
* fix detection of relative location informationOswald Buddenhagen2011-04-111-5/+7
| | | | | | | | | an empty line number does not indicate relative loc info - it may be the result of -no-ui-lines. instead, an empty file name does indicate it - no file name at all makes no sense, so this means a previous messages has set it already. and we need this additional detection, as the entire ts file may have no line number info to base the decision on at all.
* make -markuntranslated work without -idbasedOswald Buddenhagen2011-04-081-1/+1
| | | | Task-number: QTBUG-18625
* Update copyright year to 2011.Jason McDonald2011-01-1018-18/+18
| | | | Reviewed-by: Trust Me
* make the dtd reflect realityOswald Buddenhagen2010-11-021-18/+5
|
* I18n: Fix some lupdate warnings.Friedemann Kleint2010-09-141-2/+2
|
* preserve non-standard source referencesOswald Buddenhagen2010-08-301-4/+20
| | | | | | | | | the PO format doc suggests that all references are in filename:linennumber format, but some tools seem to deviate from that. so do our best to preserve such references, even if we can't do anything with them. Task-number: QTBUG-9488
* properly parse ts contexts in obsolete messagesOswald Buddenhagen2010-08-301-0/+2
|
* move the MAGIC_OBSOLETE_REFERENCE hack to the xlf file handlerOswald Buddenhagen2010-08-302-8/+15
| | | | | after all, it is pretty much specific to xlf files, even if the problem majorly concerns converted po files.
* remove spurious empty lines in the linguist tools' outputOswald Buddenhagen2010-06-034-12/+12
| | | | ConversionData::error() does already newline-terminate the strings.
* don't use qWarning() - or even qFatal()! - gratuitously.Oswald Buddenhagen2010-06-032-13/+14
| | | | Task-number: QTBUG-8044
* write PO files without duplicated message idsOswald Buddenhagen2010-06-021-7/+60
| | | | | | | | encoding the qt context as a magic comment was no particularly good idea, as it provided no disambiguation as far as gettext is concerned. so instead encode the context into msgctxt. Task-number: QTBUG-10307
* Apply f176759fc41abc4cb901c2cbaa15264f2a9ac85b to stdout too.Thiago Macieira2010-04-101-0/+4
| | | | | | | Ossi is right: on WinCE, _setmode is different from regular Windows and the docs... Reviewed-by: ossi
* the _setmode() prototype is different on win ceOswald Buddenhagen2010-04-091-0/+4
| | | | | | ... both from windows and the wince doc ... Reviewed-by: joerg
* fcntl.h doesn't seem to exist, either - contrary to an example on msdnOswald Buddenhagen2010-04-091-2/+2
|
* fix compile on winceOswald Buddenhagen2010-04-091-2/+7
| | | | Reviewed-by: joerg
* Fix compilation on solaris-g++: ctype functions are sometimes macrosThiago Macieira2010-04-011-3/+3
| | | | | | | At least with g++ 3.4 on Solaris, they are. So you can't write ::isalpha because that expands to something invalid. Reviewed-by: Trust Me
* handle qt-format PO flagsOswald Buddenhagen2010-03-311-1/+24
|
* handle encoding of PO filesOswald Buddenhagen2010-03-311-134/+202
|
* make variable naming politically correct :-DOswald Buddenhagen2010-03-311-4/+4
|
* add Plural-Forms header in PO writerOswald Buddenhagen2010-03-315-25/+64
|
* simplify arabic plural ruleOswald Buddenhagen2010-03-311-1/+1
|
* don't mark untranslated messages as fuzzy in PO filesOswald Buddenhagen2010-03-311-2/+2
| | | | ... as this is what gettext processors expect.
* support gettext POT filesOswald Buddenhagen2010-03-311-0/+14
| | | | | these are in fact the same as PO files, only that exporting to one automatically drops translations.
* fix writing of length variant separators in the singular caseOswald Buddenhagen2010-03-311-0/+2
|
* make PO header handling less of a monster hackOswald Buddenhagen2010-03-311-44/+80
| | | | | | instead of doing string editing magic, parse the header properly. don't add a template file comment, either - it's not mandatory, after all.
* fix updating of X-Source-Language PO headerOswald Buddenhagen2010-03-311-0/+3
|
* interpret source language "en" as "POSIX" (more precisely: "none specified")Oswald Buddenhagen2010-03-311-0/+2
| | | | | | | we set it to that value when writing xliff, as the header is mandatory and no better value is possible. it seems unlikely that an unqualified "english" would be used if somebody meant to actually specify a source language, so this hack should be ok.
* optimization: get rid of QString::fromUtf16() usageOswald Buddenhagen2010-02-011-1/+1
| | | | | | | | | | | | QString::fromUtf16() is slow - it does a BOM check and optionally byte swapping, which is utterly pointless when converting internal data structures which are raw utf16 in host byte order anyway. so replace it with QString::fromRawData() (for short-lived strings) or QString(const QChar *, int) (otherwise) if possible. Reviewed-by: axis Reviewed-by: mariusSO Reviewed-by: Bill King
* don't falsely complain about mismatched codecfortrOswald Buddenhagen2010-01-271-0/+1
| | | | normalize the user input first
* unshare pro post-processing codeOswald Buddenhagen2010-01-273-189/+0
| | | | | lrelease needs only the TRANSLATIONS value anyway, so there is hardly anything to share for real
* do not sort the TS filesOswald Buddenhagen2010-01-271-2/+1
| | | | really no point in doing so ...
* Merge remote branch 'mainline/4.6' into 4.6Oswald Buddenhagen2010-01-1320-20/+20
|\ | | | | | | | | Conflicts: tests/auto/linguist/lupdate/testlupdate.cpp
| * Update copyright year to 2010Jason McDonald2010-01-0620-20/+20
| | | | | | | | Reviewed-by: Trust Me
* | QFile cannot deal with crlf-translated stdio, so use binary modeOswald Buddenhagen2010-01-121-0/+12
|/ | | | | | | of course, this will break if somebody actually pipes in windows files. oh, well. Suggested-by: joao
* make qph use language attributesOswald Buddenhagen2009-11-251-5/+18
|
* the definition needs xml escaping, tooOswald Buddenhagen2009-11-251-1/+1
|
* don't write context into <definition> fieldOswald Buddenhagen2009-11-251-3/+2
| | | | | | there is really no point in doing so Reviewed-by: hjk
* qph: don't clobber <definition> fieldsOswald Buddenhagen2009-11-251-1/+1
| | | | | | | | | | the translator comment field is not written out, so reading the definition into it is basically discarding it as far as any roundtrips which arrive at qph again are concerned. the message's disambiguation seems most suitable for the task. Reviewed-by: hjk Task-number: QTBUG-4498
* fix class/struct mismatch in the bootstrap magicOswald Buddenhagen2009-11-251-2/+4
| | | | | | qlocale.h includes qobjectdefs.h which forward-declares it as a class. Reviewed-by: aportale
* fix encodings, take NOswald Buddenhagen2009-11-202-5/+11
| | | | | Task-number: QTBUG-4499 Task-number: QTBUG-5276
* don't overwrite explicitly specified CODECFORTR on UTF-16 inputOswald Buddenhagen2009-11-191-1/+1
|
* build lrelease bootstrappedOswald Buddenhagen2009-11-104-0/+49
| | | | | | | | needed for build-time qm generation in qt itself. the downsides are a) that the other bootstrapped tools grow by ~12kB (on x86) due to qdatastream being pulled in by qbytearray and qstring and b) that lrelease isn't l10n'd itself anymore (the latter could be fixed by building a non-qobject qtranslator).