Soft hyphens and line breaks (Re: Firefox Focus Screenshots 20170202-1618 (br, dsb, eo, fa, ga-IE, gd, hi-IN, hsb, lo, nb-NO, nn-NO, pt-PT, sq, th, uz))

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Soft hyphens and line breaks (Re: Firefox Focus Screenshots 20170202-1618 (br, dsb, eo, fa, ga-IE, gd, hi-IN, hsb, lo, nb-NO, nn-NO, pt-PT, sq, th, uz))

Stefan Arentz-5
Sent again because this list does not like me to post images it seems.

On Fri, Feb 3, 2017 at 9:03 AM, Stefan Arentz <[hidden email]> wrote:

>
>
> On Fri, Feb 3, 2017 at 4:39 AM, Michael Bauer <[hidden email]> wrote:
>
>> Some questions, please
>>
>> In this environment, how do I
>> a) force a line break
>> or
>> b) specify a non-breaking hyphen?
>> in order to prevent a-rithist breaking across lines, which is not
>> permitted?
>> https://people-mozilla.org/~sarentz/focus/screenshots/201702
>> 02-1618/Focus/iPhone5s/gd/iPhone5s-01Home-d41d8cd98f00b2
>> 04e9800998ecf8427e.png
>>
>
> Both line breaks and soft hyphens are supported.
>
> I am not in the best position to give advice because I only deal with
> XLIFF files. There is it a simple matter of putting a line break or &#173;
> in the element's data.
>
> For example, this:
>
>       <trans-unit id="Home.descriptionLabel2">
>         <source>Browse. Erase. Repeat.</source>
>         <target>Surfen.
> Hottentotten&#173;tenten&#173;tentoolstelling. Herhalen.</target>
>         <note>Second label for product description on the home
> screen</note>
>       </trans-unit>
>
> Translates to:
>

https://www.dropbox.com/s/tp91fyems6glza9/Screenshot%202017-02-03%2008.49.33.png?dl=0


>
>
> So the line break after "Surfen." is immediately used and the best fitting
> soft hypen in Hottentottententententoonstelling (real word!) is chosen.
>
> Couple of notes:
>
> - The &#173; is invisible when not used by the text layout engine. Ideally
> put more than one in long words to give iOS options.
>
> - Be careful with line breaks and soft hyphens. Specially forced line
> breaks. You may fix something for a small screen device, which may look
> weird on a large screen device. This is very tricky, but it is best to not
> make assumptions (linebreaks) and only give hints (soft hyphens).
>
> - If you feel something really does not look right, talk to us and we can
> probably make a code change to help.
>
> - If you use line breaks and soft hyphens and the text is still fixed (and
> truncated) on just one line then it is possible that the developers
> configured to field to have only one line. In the above example, the text
> label has 0 (zero) lines, which means 'use as many as needed, grow
> vertically'. Just post a message here or file a bug if you think we need a
> code change.
>
> How this works in the tool that you use may differ. The above is in XLIFF,
> but it may differ in tools like Pontoon. We must have an FAQ for this, if
> not, let's write one.
>
>  S.
>
>
>
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n