|Subject:||HTML and 'exdent' command (continued)|
|Date:||Sun, 23 Nov 2014 20:47:49 +0800|
|User-agent:||Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0|
The 'exdent' is difficult to style, but not impossible.
1) define the 'example' class as having flush-left margins: margin-left: 0;
2) define 'example' <pre> as: margin-left: 3.2em;
3) define the exdented line only as outside of the <pre> i.e. as top-level 'example' text.
4) Even though the 'example' class itself is defined with 'white-space: pre', to make this work, we must continue to have a <pre> tag designed in CSS specifically for the 'example' and 'display' classes to differentiate between standard and exdented text.
Here is an @example block as generated by the converter:
<pre class="example">unmodified line
</pre><pre class="example">exdented line
</pre><pre class="example">unmodified line
And here is one that looks reasonably good after style definitions have been applied:
Here is the CSS test definition for @example. @display would be similar, but not monospace.
There are certainly other ways to do it, and some of them would not generate the blank line before and after the exdented line, but this seems to be the easiest to implement in the converter. If you think it's worth some effort, I will continue experimenting with it.
On 11/23/2014 07:05 AM, Patrice Dumas wrote:
On Mon, Nov 17, 2014 at 10:26:07AM +0800, Mahlon wrote:Hello all, Yes, it can be done in CSS, and in fact I'm writing a reasonably comprehensive CSS definition file that can be applied to the texi-to-HTML output. http://www.softwaresam.us/docs/docs.htmlOk. If I understand well, you would like some integration of that in makeinfo. In any case, we can redistribute your css file in the contrib directory.The reason I bring it up is that the exdent looks bad any way I try it.But is there a way to make it look good? Does it look good if in a <span> and not a <pre>? Or is it necessarily incorporated within a main <pre> instead of having it split in 3?
Software Sam - software and tools for GNU/Linux
|[Prev in Thread]||Current Thread||[Next in Thread]|