Localized quotes

2
  • Ah, rereading your note I see the point; you want to distinguish by language, and French conventions come naturally when entering content. We'll go that route then. I'll give it a little more thought, and if I come up with what looks like a happy solution, I'll push some trial changes, for French as spoken in France (fr-FR) only.
  • edited April 4, 2011
    I completely agree with the proposed solution of replacing "space:" by "nbsp:" for it should suit to all languages.
    This way, it's up to to user to choose what he wants to be printed.

    If it can be done for citations, footnotes as well as for bibliography, it would be great!
  • Ok. (Although I'm not sure, that should not be extended to Canadian French but might be right for Belgian and Swiss French, etc.)

    [Just for fun... Actually typography is more complex: before a semicolon, an exclamation and a question marks, purists would use a narrow non-breaking space... No need to implement that for now!]
  • Actually, there's little reason not to use a narrow non-breaking space here, if we know that it's correct. I doubt it's any harder than using a standard one.
  • edited July 25, 2013
    Actually, there's little reason not to use a narrow non-breaking space here, if we know that it's correct. I doubt it's any harder than using a standard one.
    I agree it might be not harder.
    The problem is that a) we need to know the exact scope of the rule; b) from a practical point-of-view, even if zotero (csl processor) can automate that, word processors does not. MS-Word, for example, has automated nbsp (in the 90's). But I don't know anyone who, while writing her dissertation, would use narrow nbsp since it entails the use of complex keyboard combinations each time you're typing ";" or "!" or"?" (waste of time).
  • The character seems like a good candidate for a localization rule at some point in the future.
  • edited April 4, 2011
    I've pushed a change that should work its way into the next Zotero release (2.1.6). It just does a find and replace against string content, and should serve well. The replacement covers the characters mentioned above, plus double-angle quotes.

    I've used the narrow no-break space character for the replacement, since that's correct, and the output should be as correct as possible for automatically generated bibliographies.

    (This does leave one bug in the mix, I fear. For flip-flopped quotes, you might get the half width space as well, I'm not sure. If anything comes out looking not right, let me know and I'll look into it.)
  • edited October 27, 2015
    I've investigated this issue a little bit further...
    In French, there is a narrow no-break space before a colon ":" or a semicolon ";" or an exclamation mark "!" or a question mark "?" or a close-guillemet "»" and after an open-guillemet "«". [see my edit below]

    I'll change locales-fr-FR.xml according to this...
    The only issue is now for non-bibliographic text: MSWord uses a nbsp... but zotero/csl cannot do anything here.

    [That might differ in Canadian French where colon and guillemets are used with normal no-break space.]

    Sources (in case of future discussion):
    http://www.orthotypographie.fr/index.html
    http://www.orthotypographie.fr/volume-I/echelle-extrait.html#Espace
    http://www.orthotypographie.fr/volume-II/point_cardinal-proverbe.html#Ponctuation

    EDIT (feb. 2012):
    Actually, as most word processors use "normal" no-break spaces, I think that, for the sake of consistency between text and notes, this would be great if zotero/csl could use "normal" nbsp. This simple change would be a "giant leap" for French user of zotero.

    No need to use narrow nbsp then. Because of consistency and also because further researches convince me that narrow nbsp is only "right" for ";" (semicolon) "?" (question) "!" (exclamation). For colon and guillemets, it's a normal nbsp (but purists (J.-P. Lacroux) would say: thiner than nbsp, larger than narrow nbsp!! Typography...).
  • Concerning the apostrophe, I made further investigations in the bibliography, and noticed that the modification didn't apply to every data.

    It seems to me that the first apostrophe encountered is transformed, but the next one is not.
    Example with a book’s title :
    . Études sur Descartes : l'histoire d'un esprit
    becomes:
    . Études sur Descartes : l’histoire d'un esprit.

    where the first apostrophe is transformed, while the second is left unchanged.

    Any idea ?
  • You're absolutely right, I forgot to set the global option on the replace command. It will be fixed in the next release. Thanks for reporting.
  • @fbennett

    I upgraded to 2.1.6. The bibliography is now OK, but they are still some problems in the notes.

    1/ All the french left quotes in the prefix and suffix fields are preceded with an unexpected Â, as

    « la défense antique d’une individualité naturelle solidaire du nom propre socialement reconnu », « Les deux Sosies », op. cit., p. 66, et plus loin « [le] corps, [la] position sociale », p. 69.

    instead of :
    « la défense antique d’une individualité naturelle solidaire du nom propre socialement reconnu », « Les deux Sosies », op. cit., p. 66, et plus loin « [le] corps, [la] position sociale », p. 69.

    2/ Some "suppress author" which had been entered before upgrading have disappeared.
    I wonder if it could be linked to the fact that the disappearing ones all concern references whose locator = verse

    Hoping this could be settled soon
  • Re 1/ that's certainly ugly. I'm in the midst of a complete rewrite of the names formatting code in the processor (to make it cleaner and easier for other programmers to understand -- an important form of insurance for the future of the project). That work will take another week or possibly two to complete, but I'll keep this discussion bookmarked, and be sure to address this before the next release.

    Re 2/, while I can't say anything definite about the cause, at first blush that looks like it might be caused by the plugin itself -- at least it doesn't seem as though it would be caused by the processor.
  • These two points concern the "old" notes (created before upgrading).
    Creating new ones works properly.

    Both problem seem to concern the updating phase of the data base which is modified, loosing some information (suppress author) or modifying some (inserting Â)
  • If there are strong views that the issue with upgrades should be fixed, please post them here. I can look further, but for the moment I'll leave things as they are, if things are working smoothly in new documents.
  • @fbennett

    Concerning the extra Â, I thought that after having suppressed them once, I would get rid of the problem, but as soon I have to update the document they appear again and again. That means that the database is corrupted.

    Although the new footnotes seem to be OK, to have correct documents, all the footnotes would have to be completely erased and re-written (just modifying them doesn't do any good) ! It is just not possible.

    I would have hoped everything would have be settled without bothering you again, but It is just absolutely not possible to keep documents corrupted for ever.

    Please take pity on us !
  • Thanks for getting back. This is certainly not good, and I'll take a look. When this is fixed, the documents should correct themselves on refresh; the citation form rendered in the document does not affect the data in the entries inside your database/library.
  • edited April 27, 2011
    I think I've spotted the problem. For a find-and-replace operation, I had written the open guillemet into the code in visual form (which is encoded as UTF-8) instead of using the native Javascript character code (\u00ab). It should work correctly in the next Zotero release.
  • I will be happy to get the next release
  • Our international house style calls for single quotes rather than doubles around article titles, but even after coding the location as en-GB, I'm still getting double quotes. Any idea what I could do to make it render single quotes (and the doubles only if there's something quoted within the title)?
  • put this right below the info section, i.e. below
    </info>

    <locale xml:lang="en">
    <style-options punctuation-in-quote="false"/>
    <terms>
    <term name="open-quote">‘</term>
    <term name="close-quote">’</term>
    <term name="open-inner-quote">“</term>
    <term name="close-inner-quote">”</term>
    </terms>
    </locale>
  • Thank you! Worked perfectly.
  • @fbennett

    Testing the 2.1.6.r9295 about the footnotes:

    - the unexpected  preceding all the french left quotes in the prefix and suffix fields don't appear anymore.
    Much better. Thanks

    - But, all the data (excepting the authors) are transformed in small capitals!

    I used the same style, which doesn't use 'small-caps' in footnotes at all, compared two copies of the same document created with 2.0.9 and refreshed( one with 2.1.6, and the other with 2.1.6.r9295)
  • Well, that's not good. Let's start from the style. Can you paste a copy of it to gist.github.com, save it as a public gist, and post the link from the URL back here? If I can reproduce this error here, it can be fixed.
  • Here is the style:
    git://gist.github.com/990531.git
  • Thanks. This is clearly a processor bug; there is nothing wrong with your style. I won't bore you with the technical details, but this will be fixed in a new release soon.
  • Tested with 2.1.6.r9319, seems OK

    Thanks
  • @Frank:
    Did you implement the automatic replacement of space by nbsp in French locale when there is a space immediately followed by one of these marks: exclamation ( !), question ( ?), semi-colon ( ;), colon ( :), close-guillemet ( ») and when the space follows an open-guillemet (« )
    See messages from this one. (In z3.0, this automatic change is not implemented. Don't remember for z2.x)

    This would be the equivalent of the "Add non breaking space before specific punctuation marks in french text" option in LibreOffice (Tools - AutoCorrect Options - Localized Options). The only exception is in French as spoken in Canada (fr-CA) where there is a (no-break) space only before a colon ( :) and guillemet (« blabla »).
  • We certainly went through these requirements. If they're not working now, I should double-check that they're in the test suite. It might take a few days for me to get to it; drop me a not again if you don't hear anything in a week.
  • Should we work these exceptions into the CSL spec? I guess we should at least have all the info in one place.
Sign In or Register to comment.