Non-breaking space unavailable between initials and names

I could not find how to insert an non-breaking space between an initial and a name (eg A. Smith). initialize-with=". " doesn't work. It seems that a normal space is inserted by default after the initial (or the point here). Could someone help ? Many thanks in advance.

My csl :

<macro name="author">
<names variable="author">
<name delimiter=", " form="long" delimiter-precedes-last="never" initialize-with=". " and="text">
<name-part name="family" font-variant="small-caps" />
  • I don't think that can be done. There's an automatic space between a first and a lastname that you can't remove (the space/nbsp in initialize-with only affects names with multiple initials, i.e. A.S. smith vs. A. S. Smith, i.e. that doesn't affect your example at all).
    What is this required for?
  • Thanks for the answer. I need it for the citation style of a French journal (see the csl based on the ieee style at NBSp function properly with Zotero in other places. But names seem something special. I guess this is not the only style with an "A._NBSp_Smith" requirement. No idea how to solve this for the moment!
  • it's not that nbsp doesn't work, but that the delimiter between firstname and lastname (and by extension initial and lastname) can't be customized.
    Where are the requirements for this stated? It's not a general rule, see e.g ref [3] on p. 7 of the IEEE manual
  • edited September 1, 2013
    What about suggesting a change in the program? This is not a requirement in the IEEE manual but this is a very common rule in the editing process. Being (also) an editor myself, I find it painstaking and time consuming to insert NBSp in accepted papers, either in Word or in In Design, while authors should take care about the subject themselves. A style with NBSp by default between intitals and surnames would have been great for this reason. See our own manual here :
  • the relevant rule is under 3.2 for those following along.

    I can bring it up, but it won't happen quickly, unless this is a generally accepted rule in French typography, in which case we _might_ be able to put it into the processor without a spec change.
    NBSp seem to be particularly prominent in French typography, this pretty much never comes up in English, either side of the ocean.
  • edited September 9, 2013
    I looked around and I confirm that NBSp after initials and before names are widely used in French typography. However, I can not assume that all editors require them. The best would be to be able not to have systematically an automatic space between the first and lastname, i.e. to enable a replace-instruction that could change this space. But technically, I do not know if this is possible...
  • Just to confirm that it's a general rule in French typography. I'll post a link later.
    [and it would be great to make the delimiter customizable (localizable) in a future csl release.]
  • I assume a regular space is used when you have a full first name (in French in general - obviously doesn't apply to this style)?
  • edited September 11, 2013
    Yes, a regular space is used for full first names (even for this style).
    I would suggest to work on the function : initialize-with=".", but there may be a conflict with the default space inserted after a full first name.
    To be clear again, the idea is to prevent both :

    a. this visual result with consecutive notes :

    1. A._Smith,
    2. A.___Bull,
    3. A.__John,

    (spaces somehow exaggerated here)

    b. a cut after the first name at the end of the line, ie : A.
  • No, we can't put this into intialize-with:
    It's very common to have A.S. Smith (i.e. no space between initials) and we get this with initialize-with="." so this needs to be defined separately.
  • edited April 22, 2016
    Hallo! I'd like to bring up the topic again, cause in russian standart NBSp is necessary, but in my code it doesn't work at least with Word.

    <locale xml:lang="ru">
    <term initial-last-name-delimiter=""/>
    <macro name="author">
    <names variable="author">
    <name name-as-sort-order="all" sort-separator=" " initialize-with=". " delimiter=", " delimiter-precedes-last="always"/>
    <label form="short" prefix=" " text-case="lowercase"/>

    initialize-with and prefix in lable contain non breaking space as "160"
    I'd be grateful if you tell me what do I do wrong.
  • As you can see the ticket is still open, so nothing new there. But I do want to make sure that you're understanding this right: This thread is about the space between first name (initial) and last name -- is that what you're trying to set to nbsp?
  • Exactly. I need smth like "А.nbspП.nbspЩербаков".
    As I see, it's impossible for now, is it?
  • yes, I'm sorry.
  • Is there any hope it will be done?)
  • This is an interesting problem, and I think we can support the Russian and French use cases within the existing CSL framework, in a way that would not be disruptive, and leave a path open to more refined support in the next version of CSL.

    Before diving in with an outline of the issues and a proposal, I should check up on the appropriate forum, since there will likely be some back-and-forth in the discussion.

    @adamsmith: Is it okay to post initially here, or would you prefer to have a proposal directly on the ticket linked above?
  • Thank you for your attention to our request for this local feature!Looking forward to the next version of CSL.
  • fbennett - whatever you find more convenient. I agree it'd be nice to support.
  • I've gone ahead and released a version of the processor with the strategy I had in mind. All tests pass, and the new code should not have any effect on existing styles, nor on styles run in locales other than French or Russian. You can run the new code by installing one of the Propachi plugins. The plugin can and should be removed when the new processor version is adopted in a future release of Zotero.

    Here's a run-down:

    (1) In initialize-with, the non-breaking spaces &amp#xFEFF; and &amp#x00A0; are always retained for inter-initials joins, in all locales.

    (2) In the fr and ru domains only, for non-sort-ordering names only, the presence of &amp#xFEFF; or &amp#x00A0; in initialize-with will cause a normal non-breaking space (&amp#x00A0;) to be used for the join between initials and first word of the family name.

    To make use of the new functionality, just set the non-breaking space to be used for inter-initials joins in initialize-with (i.e. for the join between the "A." and the "P." in "A.P. Herbert"), and things should just work when the style is run in a French or Russian locale.

    The only change from current behaviour (apart from covering the French and Russian use cases) is that initials in styles that use one of the non-breaking spaces in initialize-with will be clustered together in non-Russian, non-French locales. That seems useful and low-impact, but if that is not desired, we can revert to ordinary space (or no-space) for inter-initials joins in the other locales.

    It would be better for the implicit use of &amp#x00A0; as the initials-to-name join to be controlled in the locale. In the next version of CSL, a boolean cs:style-options attribute could be introduced for that purpose; but this should hold things together for the present.
  • edited April 24, 2016
    suggestions for how to call the style option? initial-name-delimiter?

    so we'd have
    initial-name-delimiter=" " (The current status)
    initial-name-delimiter="&amp;#160;" (nbsp)
    initial-name-delimiter="" no space at all (not sure if that exists, but once we have the option, why restrict it.)
    and so on.
  • The delimiter itself would be in the initialize-with options in the body of the style. The locale option would just be a boolean to indicate that the non-break join should extend to the gap between the initials and the family name element. An (excessively verbose) name for it could be something like:
  • edited April 24, 2016
    I don't think that's a good idea. We'd want A.A.&#160;Smith to be possible, so it should be possible to set initialize-with="" and still have a nbsp between initial and last name, no?
  • No one has asked for it, but if reserving the option is important, the i-to-f join could be set in a separate attribute. Wouldn't it be confusing to have one delimiter set in the style body and another in the locale, though?
  • Good point. On the other hand, might be nice to have this easily localizable. I've asked Rintze to see what he says.
  • I'm fine with @fbennett's current solution, but I agree with @adamsmith that we should eventually be able to cover the case of no-space delimiters between initials with a custom delimiter after the initials and before the family name. (maybe with an attribute "after-initials-delimiter", in line with the existing "after-collapse-delimiter"?)
  • but we'd want to make this a name attribute, even if that means it's not localizable?
  • Localization seems pretty important for this one.

    You could use both approaches, so that joins are set with two name attributes (one for initial-initial, another for initial-familyName), and the "degrading" of non-breaking spaces to breaking counterparts is controlled with a locale setting.

    That would make things a bit cluttered, but it might not be too bad, since the locale setting, at least, would almost never be touched.

    If clutter is an issue, the joins could all be moved into the locale, if styles are assumed to be internally consistent on that. That might be kinda risky though, since it would be hard to ramp up flexibility if unexpected use cases crop up later.
  • Some additional questions:

    * are there cases where initials should be separated by non-breaking spaces, but the last initial and family name with a regular space? Or vice versa (regular spaces between initials, but non-breaking space between last initial and family name)? If we can rule out either case, things get a little easier.
    * are there cases where family names that consist of multiple parts should also contain non-breaking spaces (e.g. in "J. le Carre", between "le" and "Carre")?
  • @Rintze, as for Russian standart there are no such cases, all the parts should "stay together" even in foreign names, e.g. "F. de Saussure". So I can't imagine any case with a regular spase between no parts of the name.
Sign In or Register to comment.