summaryrefslogtreecommitdiff
path: root/bk_info.c (unfollow)
Commit message (Collapse)Author
2014-03-30Silence compiler warnings on OS X 10.9.Simon Tatham
[originally from svn r10166]
2013-03-10Add \s for 'strong' text, i.e. bold rather than italics. I've missedSimon Tatham
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]
2012-08-29Revamp of the Halibut error handling mechanism.Simon Tatham
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]
2007-04-08List some documentation sources, and another todo item.Ben Harris
[originally from svn r7454]
2007-04-08Remove heading underlines from todo list.Ben Harris
[originally from svn r7453]
2007-04-08Add support for doing different underlining of different heading levelsBen Harris
in the Info backend, with the defaults chosen to match what Emacs recognises and renders prettily. [originally from svn r7452]
2007-04-08Another observation about indices.Ben Harris
[originally from svn r7451]
2007-04-07A few thoughts I had while actually using Halibut's Info output.Ben Harris
[originally from svn r7449]
2006-06-02Introduce global (cross-backend) \cfg{contents} and \cfg{index}Simon Tatham
commands, allowing the fixed words "Contents" and "Index" generated in various output formats to be reconfigured into other languages. [originally from svn r6724]
2005-03-08Ability to specify multiple arguments to \cfg{html-template-fragment};Jacob Nevins
Halibut will output fragment names in all specified formats. (I forget now precisely why I thought this was necessary, but it seems potentially useful.) Also ensure that legal fragment names are generated even if none of the characters from the original turn out to be legal (e.g., %k with an entirely numeric keyword), and correct an untruth I inserted in the documentation of this. (This commit hits more than just the HTML backend as I've generalised an error message, and fixed a fault in the info backend's error handling while there.) [originally from svn r5457]
2004-08-06Make sure (paragraph)->private_data is defined in all cases, on generalJacob Nevins
principles (it may be unnecessary). Perhaps we should do this for (word)->private_data too. [originally from svn r4412]
2004-08-06Fix crash in Info backend: if a \[Kk] to a \B or \n was followed in aJacob Nevins
paragraph by another \[Kk], Bad Things would happen. [originally from svn r4411]
2004-06-27Sort out error handling everywhere a charset name is converted intoSimon Tatham
an integer charset ID. [originally from svn r4317]
2004-06-12Switch the memory allocation macros from the Halibut onesSimon Tatham
(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]
2004-04-23General configurability upgrade for the info back end.Simon Tatham
[originally from svn r4131]
2004-04-22bk_text and bk_info both need to know the on-screen width ofSimon Tatham
characters in order to wrap and align them properly. Therefore, they should be using wcwidth(). So here are a couple of wrappers on wcwidth(), one which filters out the Unicode characters not representable in the target charset, and one which converts _from_ a charset to Unicode before calling wcwidth(). bk_text and bk_info should now align correctly even in the face of unsupported characters and Japanese. [originally from svn r4116]
2004-04-21Charset support for the info backend (\cfg{info-charset}). (ThisSimon Tatham
checkin touches other files because a function in bk_text.c turned out to be of more general use so I moved it out into ustring.c.) [originally from svn r4111]
2004-04-20Infrastructure changes for character set support. ustrtoa,Simon Tatham
ustrfroma, utoa_dup and ufroma_dup now take a charset parameter, and also have a variety of subtly distinct forms. Also, when a \cfg directive is seen in the input file, the precise octet strings for each parameter are kept in their original form as well as being translated into Unicode, so that when they represent filenames they can be used verbatim. [originally from svn r4097]
2004-04-19Better robustness when backends encounter a Unicode character notSimon Tatham
representable in the output character set. [originally from svn r4094]
2004-04-13Initial work on PS and PDF output. Because these two backends shareSimon Tatham
an enormous amount of preprocessing and differ only in their final output form, I've introduced a new type of layer called a `pre-backend' (bk_paper.c is one). This takes all the information passed to a normal backend and returns an arbitrary void *, which is cached by the front end and passed on to any backend(s) which state a desire for the output of that particular pre-backend. Thus, all the page layout is done only once, and the PS and PDF backends process the same data structures into two output files. Note that these backends are _very_ unfinished; all sorts of vital things such as section numbers, list markers, and title formatting are missing, the paragraph justification doesn't quite work, and advanced stuff like indexes and PDF interactive features haven't even been started. But this basic framework generates valid output files and is a good starting point, so I'm checking it in. [originally from svn r4058]
2004-04-10The Emacs and Jed info readers don't like my index format: Info menuSimon Tatham
items of the form `* stuff: Section 1.2.' are parsed by standalone info as `Section 1.2' followed by a period, but are parsed by other readers as `Section 1' followed by a period and then some spare text. Therefore, I've changed strategy, and the index is now full of *Note cross-references rather than menu items. On the plus side, this means there are no longer any special characters which we can't tolerate in an index entry; on the minus side, my shiny new infrastructure for tracking the filepos of index entries is now rendered pointless. I'll leave it in, though, since it may come in handy again. [originally from svn r4053]
2004-04-10Info backend now takes care to avoid magic characters in node namesSimon Tatham
and index terms (the Info format doesn't like them). In the course of this I've had to introduce some infrastructure for carrying a filepos forward from the definition of every RHS index term so that a particular backend can provide a usefully localised report of which index term had a problem. [originally from svn r4051]
2004-04-09Add a config directive to generate the INFO-DIR-ENTRY things thatSimon Tatham
appear to be used to automatically construct /usr/info/dir. [originally from svn r4049]
2004-04-09Added an info(1) backend, which constructs .info files directlySimon Tatham
without going through the .texi source stage. A few things left to do, notably documentation, but the basics all seem to be there. [originally from svn r4047]