<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>sirocco</author_name>
  <author_url>https://blog.hatena.ne.jp/sirocco/</author_url>
  <blog_title>sirocco の書いてもすぐに忘れるメモ</blog_title>
  <blog_url>https://sirocco.hatenadiary.org/</blog_url>
  <categories>
    <anon>PostScript</anon>
  </categories>
  <description>文字列を出力して行末に達したときは、改行して次の行の先頭から表示しなければなりません。 行末に達したかどうかは currentpoint で現在の位置を求め、 stringwidth で印刷しようとする文字列の幅を求めれば良いのですが、長い文章全体の幅を求めても意味がありません。文字列を1文字と残りの文字列に分けて、 その1文字の幅から改行すべきかどうか判定するようにします。 PostScriptでは1バイトで文字列から一部文字列を取得できますが、EUC-JP の文字列は1バイト、2バイト、3バイト文字が入り乱れています。 1バイト、2バイト、3バイト文字と長さを考慮しながら、先頭の1文字と残…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fsirocco.hatenadiary.org%2Fentry%2F20120830%2F1346308462&quot; title=&quot;1バイト、2バイト、3バイト文字の入り乱れたEUC-JP文字列を1文字ずつ出力する(PostScript)。 - sirocco の書いてもすぐに忘れるメモ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2012-08-30 15:34:22</published>
  <title>1バイト、2バイト、3バイト文字の入り乱れたEUC-JP文字列を1文字ずつ出力する(PostScript)。</title>
  <type>rich</type>
  <url>https://sirocco.hatenadiary.org/entry/20120830/1346308462</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
