Coder Social home page Coder Social logo

Comments (10)

davidfraser avatar davidfraser commented on July 20, 2024

\ Bug #80 has been marked as a duplicate of this bug. *

from translate.

davidfraser avatar davidfraser commented on July 20, 2024

Hmmm, not sure what the best thing to do here is, so will look at this later.
Thanks for reporting.

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

Created [attachment 35](http://bugs.locamotion.org/attachment.cgi?id=35)

Mozilla DTD with spaces

This is a cut down version of update.dtd from Mozilla Firefox 1.5. It contains
only pretty printed entries that have uneeded spaces, everything else has been
deleted.

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

There is also a second problem. Items that are converted seem to be using CRLF
within the entity so when we transfer this to PO we have ^M characters carried
over. These should be removed.

I haven’t created a seperate bug report as this can probably be fixed with the
same effort to fix the preceding spaces.

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

Created a test and patch. Committed to CVS. This solves the starting
whitespace but not the line endings problem.

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

See Bug #79 for the line ending problem.

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

That was Bug #86 for the line ending problem!

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

This needs some more thinking in terms of the followin:
- spaces at the start of the string (test committed to 0.8 branch)
- how to wrap subsequent strings together (my guess is we convert the newline
and subsequent whitespace into a single whitespace character)

So reopening this bug

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

Comitted a fix to CVS with tests. We now do the following:
- Single line elements are left untreated
- Multiline
\* Space at the start of the first line are preserved
\* Whitespace at the start of all subsequent lines is removed
\* All lines except the last have one whitespace character
(ensures that when join lines we don’t join words inadvertantly.)

from translate.

dwaynebailey avatar dwaynebailey commented on July 20, 2024

Comitted a test to 0.8 branch test_po2dtd.py v 1.7.2.3 to validate merging
translations back into a pretty printed entity

from translate.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.