Commit graph

38 commits

Author SHA1 Message Date
Abs62 fd28252253 Dsl: Allow dsl tags before subcard '@' sign 2017-07-04 17:41:38 +03:00
Abs62 992f800263 Dsl: More handle unescaped '@' symbols 2017-07-03 22:45:00 +03:00
Abs62 64afb464ed Dsl: Handle unescaped '@' symbols 2017-07-03 18:12:22 +03:00
Abs62 af0a6f42cc Correct some log messages 2017-06-22 18:02:04 +03:00
Abs62 ae767ab06f DSL: Handle "id" and "name" attributes in "lang" tag 2016-12-22 22:58:01 +03:00
Abs62 b7769c6df1 DSL: Fix escaped symbols handling in <<...>> tag 2015-04-14 18:01:16 +03:00
Abs62 450130cd97 DSL: Handle [video] and [br] tags 2014-10-29 17:46:42 +03:00
Abs62 eac157af29 DSL: Fix accent tags in "<<...>>" references 2014-10-02 17:53:12 +04:00
Abs62 4120213ee8 Rename "DPRINTF" and "FDPRINTF" debug macro 2014-05-11 01:02:31 +04:00
Abs62 9754f5f479 DSL: Fix headwords normalizing 2014-04-24 22:56:47 +04:00
Abs62 01b8ae5e17 DSL: Fix case of several headwords per one insided card 2014-04-24 17:56:38 +04:00
Abs62 362acce554 Dsl: A little improve of unmatched tags diagnostic 2014-04-18 16:34:44 +04:00
Abs62 9ad0d5f985 Implement full-text search 2014-04-16 20:18:28 +04:00
Abs62 95a96852bc DSL: Strip unsorted parts in links to insided cards 2014-02-19 17:45:54 +04:00
Abs62 444938a330 Fix logging to file UTF-8 encoded messages 2013-11-16 22:34:09 +04:00
Abs62 e9ce9c89e8 DSL: Avoid breaking of [m] tag by closing some other tag 2013-11-08 16:53:22 +04:00
Tvangeste 148fd1f275 Fix compilation failures with Visual C++ 2012 (issue #375) 2013-08-07 20:29:36 +02:00
Abs62 4af2d43dd2 DSL: Strip comments "{{...}}" when reading file 2013-07-07 14:48:37 +04:00
Tvangeste f0a122e740 DSL: properly handle [m] tag
In short, [m] = [m0].
2013-07-03 16:00:56 +02:00
Abs62 92db6d2d3e DSL: expand subcard links in card 2013-06-07 16:58:10 +04:00
Tvangeste 05070b4fc8 Eliminate some compiler warnings (in Release mode). 2013-02-04 14:46:52 +01:00
Abs62 93fba54848 Fix compilation under 64-bit linux 2012-11-29 16:56:55 +04:00
Abs62 9367be34dc Handle tags in insided card header after "~" expanding for dsl dictionaries 2012-11-26 23:17:58 +04:00
Abs62 af1403da2d Handle "^~" combination in dsl dictionaries 2012-11-26 23:16:10 +04:00
Abs62 07cbdb3b02 Handle insided cards in dsl dictionaries 2012-11-22 17:03:07 +04:00
Abs62 8c8642fdfa Call gzrewind() before gzseek() for uncompressed files 2012-11-05 20:05:58 +04:00
Abs62 2a215927ce Fix some warnings 2012-10-31 17:58:35 +04:00
Abs62 0da4b83dd7 Fix keywords per one article limitation for DSL dictionaries 2012-09-08 01:32:49 +04:00
Abs62 535fe0d3e0 Update year in copyright notices. 2012-02-21 01:47:14 +04:00
Abs62 f8151aa338 XDXF support - some improvements 2012-01-25 20:35:00 +04:00
Abs62 2763b74635 Use file names in UTF-8. Fix issue #30. 2011-09-09 16:05:28 +04:00
Denis Loginov a82a96e6af Added full support for both 32- and 64-bit Intel Macs.
The universal binary is now built seamlessly with 'Cocoa: Mac binary package for Mac OS X 10.5-10.6' (works in 10.7 as well).

Signed-off-by: Denis Loginov <dinvlad@gmail.com>
2011-08-07 21:04:53 -04:00
Tvangeste 57a928510c Fix for #23: Failure to index a dictionary in UTF-8 format on Windows.
Here's what happens. At some moment during dictionary conversion,
in DslScanner::readNextLine(), whe call iconv(), when both buffers
are of size 4 (the conversion is from UTF-8 to UTF-16).

Now, the dictionary contains two em-dash symbols at that position,
one after another, each is encoded in 3 bytes in UTF-8. So, the
input buffer of size 4 contains entire first em-dash (3 bytes)
and the first byte from the second em-dash.

Calling iconv() on Linux leads to Iconv::NeedMoreOut (E2BIG),
which makes sense, since we converted the first char and there is
no more space in the output buffer.

Calling iconv() on Windows leads to Iconv::NeedMoreIn (EINVAL),
which *also* makes sense, since we converted the first char, started
to look at the second one and noticed that it is incomplete.

The difference is only what iconv() checks first, the state
of the input or the state of the output. And it seems that it
does different things on Windows and Linux.

The patch takes this into account and resolves the conversion
problem on Windows: the only error condition that requires
to throw an encoding error is when outBytesLeft is non-empty,
that means that iconv didn't convert anything.
2011-07-01 14:21:57 +02:00
Abs62 7de7fcc8df Replace fprintf(stderr,...) in code by a macro FDPRINTF 2011-06-20 00:29:11 +04:00
Konstantin Isakov 92eceb8cad Change email from @users.berlios.de to @goldendict.org. 2010-12-09 15:31:50 +03:00
Konstantin Isakov 953d9237a3 Update copyright to span to 2011.
Better early than late, this year is ending anyway.
2010-11-14 18:47:03 +03:00
Konstantin Isakov 014731fa85 Limit the number of expanded optional parts in DSL to at most 32 to prevent resource exhaustion. 2010-09-28 21:55:53 -07:00
Konstantin Isakov ab88fa4867 Drop the src/ directory. It's superfluous. 2010-05-15 16:42:18 +04:00
Renamed from src/dsl_details.cc (Browse further)