ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@googlemail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Error while compiling : ! String contains an invalid utf-8 sequence.
Date: Mon, 28 Nov 2011 10:20:51 +0100	[thread overview]
Message-ID: <79DE5C6A-FFAA-47E5-ACA8-026426BC768E@googlemail.com> (raw)
In-Reply-To: <CAA5sP+9RR2npxuTcXnW9-kdcJrjFH7wJ1rZxyOvO9xdvut2_-g@mail.gmail.com>


Am 26.11.2011 um 00:56 schrieb Alexandre Krispin:

> Now that japanese display correctly, there is still another problem. Japanese sentences (long titles in bibliography) don't break at the end of line. I have tested the behavior of japanese with entire paragraphs, and I get the same problem as in the bibliography, lines don't break and go "through" the page.

As I already told you need “\setscript[hanzi]” to enable linbreaks for chinese and japanese.

Instead of a global setting you can also write

\startscript[hanzi]
…
\stopscript

to enable linebreaking for a area.

Another valid form for \setscript[hanzi] is the command \hanzi which is a shortcut for the longer definition.

> Though I have looked to documentation about chinese on the wiki, none helped me to solve this problem. Does someone have any idea ?
> 
> Here is a minimal example with a paragraph sample in japanese :
> %%%%%%%%%beginning of file%%%%%%%%%%
> \usemodule[simplefonts]
> \setmainfont[HeiseiMinStd-W3]
> \definesimplefonttypeface[jpn][HeiseiMinStd-W3]
> \setupbodyfont[12pt]
> \setuptolerance[\v!verytolerant,\v!stretch]

Don’t use the “\v!” prefix for settings in your document, in this case it’s harmless but there can be cases
where you don’t get the expected result of this because in normal text “\v” is a command to place a accent
over the next character (here the “!”).

> \enableregime[utf]

This is not necessary because MkIV use UTF-8 by default.

> \usemodule[typearea]
> \setupTypeArea[bcor=30mm,alphabets=2.6,oneside]

You can’t mix keywords and assignments in the same argument of a setup command,
to use the onside option you have to write “oneside=yes”.

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


  parent reply	other threads:[~2011-11-28  9:20 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-25 18:50 Alexandre Krispin
2011-11-25 19:03 ` Christian
2011-11-25 20:09   ` Hans Hagen
2011-11-25 22:13     ` Alexandre Krispin
2011-11-25 23:56     ` Alexandre Krispin
2011-11-27 13:33       ` Mojca Miklavec
2011-11-27 16:13         ` Alexandre Krispin
2011-11-28  9:20       ` Wolfgang Schuster [this message]
2011-12-07  8:28     ` Thomas A. Schmitz
2011-12-07 16:37       ` Alexandre Krispin
2011-12-07 17:45         ` Hans Hagen
2011-11-26  9:35 ` Ulrike Fischer
2011-11-26 10:44   ` Alexandre Krispin
2011-11-26 11:39     ` Wolfgang Schuster
2011-11-26 11:41       ` Alexandre Krispin
     [not found] <mailman.901.1322405047.4232.ntg-context@ntg.nl>
2011-11-28  7:08 ` S Barmeier
2011-11-28  8:42   ` Alexandre Krispin
2011-11-30 12:25     ` Alexandre Krispin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=79DE5C6A-FFAA-47E5-ACA8-026426BC768E@googlemail.com \
    --to=schuster.wolfgang@googlemail.com \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).