<feed xmlns='http://www.w3.org/2005/Atom'>
<title>halibut/bk_text.c, branch master</title>
<subtitle>My halibut tree</subtitle>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/'/>
<entry>
<title>Change plain text output formatting</title>
<updated>2018-03-18T14:57:24+00:00</updated>
<author>
<name>Franklin Wei</name>
<email>me@fwei.tk</email>
</author>
<published>2018-03-17T23:19:04+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=c985a69bd38c244327c70af80ab9d04b07fbe8b3'/>
<id>c985a69bd38c244327c70af80ab9d04b07fbe8b3</id>
<content type='text'>
Uses a # to mark section titles, and a &gt;&gt; to indicate code sections,
which otherwise had no formatting to distinguish them from the rest of
the text. This helps with the conversion of the puzzles help text to a
format the sgt-puzzles rockbox port can use.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Uses a # to mark section titles, and a &gt;&gt; to indicate code sections,
which otherwise had no formatting to distinguish them from the rest of
the text. This helps with the conversion of the puzzles help text to a
format the sgt-puzzles rockbox port can use.
</pre>
</div>
</content>
</entry>
<entry>
<title>Silence compiler warnings on OS X 10.9.</title>
<updated>2014-03-30T07:48:03+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2014-03-30T07:48:03+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=18e0f32b292316a4db3bb0bde1570a73ee60b0bd'/>
<id>18e0f32b292316a4db3bb0bde1570a73ee60b0bd</id>
<content type='text'>
[originally from svn r10166]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[originally from svn r10166]
</pre>
</div>
</content>
</entry>
<entry>
<title>Add \s for 'strong' text, i.e. bold rather than italics. I've missed</title>
<updated>2013-03-10T16:58:01+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2013-03-10T16:58:01+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=dcf080aa0e011de37a154e9e8a97dd7546a4a1b1'/>
<id>dcf080aa0e011de37a154e9e8a97dd7546a4a1b1</id>
<content type='text'>
this a couple of times in Halibut markup recently (in particular, it's
handy to have a typographical distinction between 'this term is
emphasised because it's new' and 'this term is emphasised because I
want you to pay attention to it'), so here's an implementation,
basically parallel to \e.

One slight oddity is that strong text in headings will not be
distinguished in some output formats, since they already use bolded
text for their headings.

[originally from svn r9772]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
this a couple of times in Halibut markup recently (in particular, it's
handy to have a typographical distinction between 'this term is
emphasised because it's new' and 'this term is emphasised because I
want you to pay attention to it'), so here's an implementation,
basically parallel to \e.

One slight oddity is that strong text in headings will not be
distinguished in some output formats, since they already use bolded
text for their headings.

[originally from svn r9772]
</pre>
</div>
</content>
</entry>
<entry>
<title>Revamp of the Halibut error handling mechanism.</title>
<updated>2012-08-29T18:13:11+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2012-08-29T18:13:11+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=1489dc15967970576d08f3f2b22c6e1c939bcbcf'/>
<id>1489dc15967970576d08f3f2b22c6e1c939bcbcf</id>
<content type='text'>
I'm not quite sure why I ever thought it was a good idea to have a
central variadic error() function taking an integer error code
followed by some list of arguments that depend on that code. It now
seems obvious to me that it's a much more sensible idea to have a
separate function per error, so that we can check at compile time that
the arguments to each error call are of the right number and type! So
I've done that instead.

A side effect is that the errors are no longer formatted into a
fixed-size buffer before going to stderr, so I can remove all the
%.200s precautions in the format strings.

[originally from svn r9639]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I'm not quite sure why I ever thought it was a good idea to have a
central variadic error() function taking an integer error code
followed by some list of arguments that depend on that code. It now
seems obvious to me that it's a much more sensible idea to have a
separate function per error, so that we can check at compile time that
the arguments to each error call are of the right number and type! So
I've done that instead.

A side effect is that the errors are no longer formatted into a
fixed-size buffer before going to stderr, so I can remove all the
%.200s precautions in the format strings.

[originally from svn r9639]
</pre>
</div>
</content>
</entry>
<entry>
<title>Now that you can specify negative indents in Halibut text mode, it's</title>
<updated>2012-05-04T17:37:24+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2012-05-04T17:37:24+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=8c69083e9d9358e9c4ae6bed1c4a69af94b78796'/>
<id>8c69083e9d9358e9c4ae6bed1c4a69af94b78796</id>
<content type='text'>
possible to specify an indent which is _overall_ negative, i.e.
intended to be off the left-hand side of the text file. There's no
nice way to handle this, but printing O(2^32) spaces in a while (n--)
loop is particularly bad. Fix the loop to read while (n-- &gt; 0), so
that at least it doesn't get _that_ badly confused.

[originally from svn r9491]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
possible to specify an indent which is _overall_ negative, i.e.
intended to be off the left-hand side of the text file. There's no
nice way to handle this, but printing O(2^32) spaces in a while (n--)
loop is particularly bad. Fix the loop to read while (n-- &gt; 0), so
that at least it doesn't get _that_ badly confused.

[originally from svn r9491]
</pre>
</div>
</content>
</entry>
<entry>
<title>Allow a hastily selected subset of the output formats to also accept</title>
<updated>2009-10-24T09:33:21+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2009-10-24T09:33:21+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=6c481aff452a0eed147fc73144b461fe7c263d9e'/>
<id>6c481aff452a0eed147fc73144b461fe7c263d9e</id>
<content type='text'>
"-" as a special file name meaning standard output. I've restricted
it to just those output formats which can predictably output only
one file, just for the sake of not having to faff too much with the
others.

Probably what I should have done for all of this would have been to
write a set of wrappers around fopen, fclose and everything in
between, and use them everywhere. Those wrappers would uniformly
detect "-" and convert it into stdin or stdout as appropriate, would
avoid fclosing those files for real when told to close them, and
would also be able to handle reading a little bit of data from the
start of a file and then pushing it all back even if the file were
not seekable (which would allow input.c to lose the ugly special
case whereby it can't currently read font files from standard
input).

[originally from svn r8729]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
"-" as a special file name meaning standard output. I've restricted
it to just those output formats which can predictably output only
one file, just for the sake of not having to faff too much with the
others.

Probably what I should have done for all of this would have been to
write a set of wrappers around fopen, fclose and everything in
between, and use them everywhere. Those wrappers would uniformly
detect "-" and convert it into stdin or stdout as appropriate, would
avoid fclosing those files for real when told to close them, and
would also be able to handle reading a little bit of data from the
start of a file and then pushing it all back even if the file were
not seekable (which would allow input.c to lose the ugly special
case whereby it can't currently read font files from standard
input).

[originally from svn r8729]
</pre>
</div>
</content>
</entry>
<entry>
<title>Use of \lcont in the document preamble caused an assertion failure.</title>
<updated>2009-01-20T18:34:41+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2009-01-20T18:34:41+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=3db1d2fcfbee684656ff3543eb1a01bb9fe3f657'/>
<id>3db1d2fcfbee684656ff3543eb1a01bb9fe3f657</id>
<content type='text'>
Fix it.

[originally from svn r8421]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix it.

[originally from svn r8421]
</pre>
</div>
</content>
</entry>
<entry>
<title>New option *-section-shownumber, alongside *-section-numeric and in</title>
<updated>2008-02-25T19:36:12+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2008-02-25T19:36:12+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=0d791fb645abb77b339d90c95882ef315d1f912c'/>
<id>0d791fb645abb77b339d90c95882ef315d1f912c</id>
<content type='text'>
both the back ends which currently support that, to leave out
chapter and section numbers totally in section headings. Can be
useful for publishing man pages (which don't normally want section
numbers) on the web.

[originally from svn r7892]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
both the back ends which currently support that, to leave out
chapter and section numbers totally in section headings. Can be
useful for publishing man pages (which don't normally want section
numbers) on the web.

[originally from svn r7892]
</pre>
</div>
</content>
</entry>
<entry>
<title>Sort out error handling everywhere a charset name is converted into</title>
<updated>2004-06-27T13:18:32+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2004-06-27T13:18:32+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=d87fabeacea32abba73d67f991f9e523991369c7'/>
<id>d87fabeacea32abba73d67f991f9e523991369c7</id>
<content type='text'>
an integer charset ID.

[originally from svn r4317]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
an integer charset ID.

[originally from svn r4317]
</pre>
</div>
</content>
</entry>
<entry>
<title>Switch the memory allocation macros from the Halibut ones</title>
<updated>2004-06-12T20:31:03+00:00</updated>
<author>
<name>Simon Tatham</name>
<email>anakin@pobox.com</email>
</author>
<published>2004-06-12T20:31:03+00:00</published>
<link rel='alternate' type='text/html' href='https://www.franklinwei.com/cgit/halibut/commit/?id=a5d800d080a9eb557082042216636ac872eac7ec'/>
<id>a5d800d080a9eb557082042216636ac872eac7ec</id>
<content type='text'>
(mknew/mknewa/resize) to the PuTTY ones (snew/snewn/sresize). snewn
and mknewa have their arguments opposite ways round; this may make
the change initially painful but in the long term will free me of a
nasty context switch every time I move between codebases. Also
sresize takes an explicit type operand which is used to cast the
return value from realloc, thus enforcing that it must be correct,
and arranging that if anyone tries to compile Halibut with a C++
compiler there should be a lot less pain.

[originally from svn r4276]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(mknew/mknewa/resize) to the PuTTY ones (snew/snewn/sresize). snewn
and mknewa have their arguments opposite ways round; this may make
the change initially painful but in the long term will free me of a
nasty context switch every time I move between codebases. Also
sresize takes an explicit type operand which is used to cast the
return value from realloc, thus enforcing that it must be correct,
and arranging that if anyone tries to compile Halibut with a C++
compiler there should be a lot less pain.

[originally from svn r4276]
</pre>
</div>
</content>
</entry>
</feed>
