← Back to team overview

kicad-developers team mailing list archive

Re: Re: We should decide a quoting convention...

 

--0015174c1cd058ea6f047b516a45 Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

2009/12/22 vladimir_uryvaev <vovanius@...>

>
>
>
>
> --- In kicad-devel@xxxxxxxxxxxxxxx <kicad-devel%40yahoogroups.com>,
> "Lorenzo" <lomarcan@...> wrote:
> >
> > ... for strings inside data files.
> >
> > pcbnew eats texts containing "
> > eeschema IIRC fails with strings beginning with #
> > The \n notation for multiline text had issues too IIRC (but maybe it's
> fixed now)
> >
> > Also cvpcb truncates the names containing extended characters
> >
> > Keep that in mind for the 'new' file I/O system :P
> >
> I think we should get some escape coding which translates dangerous symbo=
ls
> to safe ones, like it done in SLIP protocol.
> For example, sequence of "`" (grave) character followed by character with
> code n, should be treated as character code (n^0x20). So symbols get thes=
e
> escape codes: '\n' -> '`J', '"' -> '`b', '#' -> '`c', '`' -> '` ' etc.
>
> _
>
>=20
>

Is it reinventing the wheel? This is most common these days in open source
projects having test formats to support UTF-8 with most classic C escape
sequences with \x or \dddd (where x are letters and dddd are codes). Then
string are enclosed in " (double-quotes) and multiline is divided by \=E2=
=86=B5
(backslash+cr).

Does wxWidgets have a facility for such file handling with UTF-8?

--=20
Manveru
jabber: manveru@...
gg: 1624001
http://www.manveru.pl
 --0015174c1cd058ea6f047b516a45 Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<br><br><div class=3D"gmail_quote">2009/12/22 vladimir_uryvaev <span dir=3D=
"ltr">&lt;<a href=3D"mailto:vovanius@...";>vovanius@...</a>&gt;</span><b=
r><blockquote class=3D"gmail_quote" style=3D"border-left: 1px solid rgb(204=
, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">













<div style=3D"background-color: rgb(255, 255, 255);">
<span>=C2=A0</span>


<div>
<div>


<div>
=20=20=20=20=20=20
=20=20=20=20=20=20
<p></p><div class=3D"im"><br>
<br>
--- In <a href=3D"mailto:kicad-devel%40yahoogroups.com"; target=3D"_blank">k=
icad-devel@xxxxxxxxxxxxxxx</a>, &quot;Lorenzo&quot; &lt;lomarcan@...&gt; wr=
ote:<br>
&gt;<br>
&gt; ... for strings inside data files.<br>
&gt; <br>
&gt; pcbnew eats texts containing &quot;<br>
&gt; eeschema IIRC fails with strings beginning with #<br>
&gt; The \n notation for multiline text had issues too IIRC (but maybe it&#=
39;s fixed now)<br>
&gt; <br>
&gt; Also cvpcb truncates the names containing extended characters<br>
&gt; <br>
&gt; Keep that in mind for the &#39;new&#39; file I/O system :P<br>
&gt;<br></div>
I think we should get some escape coding which translates dangerous symbols=
to safe ones, like it done in SLIP protocol.<br>
For example, sequence of &quot;`&quot; (grave) character followed by charac=
ter with code n, should be treated as character code (n^0x20). So symbols g=
et these escape codes: &#39;\n&#39; -&gt; &#39;`J&#39;, &#39;&quot;&#39; -&=
gt; &#39;`b&#39;, &#39;#&#39; -&gt; &#39;`c&#39;, &#39;`&#39; -&gt; &#39;` =
&#39; etc.<br>

<br>


</div>
=20=20=20=20=20

=20=20=20=20
<div style=3D"color: rgb(255, 255, 255); min-height: 0pt;">_</div></div=
></div>

<img src=3D"" height=3D"1" width=3D"1"> <br>

<div style=3D"color: rgb(255, 255, 255); min-height: 0pt;"></div>


</div>



=20=20






</blockquote></div><br>Is it reinventing the wheel? This is most common the=
se days in open source projects having test formats to support UTF-8 with m=
ost classic C escape sequences with \x or \dddd (where x are letters and dd=
dd are codes). Then string are enclosed in &quot; (double-quotes) and multi=
line is divided by \=E2=86=B5 (backslash+cr).<br>
<br>Does wxWidgets have a facility for such file handling with UTF-8?<br cl=
ear=3D"all"><br>-- <br>Manveru<br>jabber: <a href=3D"mailto:manveru@manveru=
.pl">manveru@...</a><br> =C2=A0 =C2=A0 gg: 1624001<br> =C2=A0 <a hre=
f=3D"http://www.manveru.pl";>http://www.manveru.pl</a><br>

 --0015174c1cd058ea6f047b516a45-- 




Follow ups

References