List Info

Thread: Any source of Plain-text stylesheets?




Any source of Plain-text stylesheets?
country flaguser name
Sweden
2007-08-12 19:54:42
I need to find docbook stylesheets that can strip off xml
markup, as  
well as any content that is not plaintext.
Do someone on this list know of any such source.
Alternately, do some one know of any grammar checker for the
english  
language, hosted on Mac OS X,
that retains xml markup.

-------------------------------------
This sig is dedicated to the advancement of Nuclear Power
Tommy Nordgren
tommy.nordgrencomhem.se




------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
user name
2007-08-13 01:09:37
Hi,

I'm not quite sure what you're asking for.  If you want a stylesheet that simply returns the text from an XML document and does nothing else, then I believe something as simple as:

<xsl:template match=&quot;/"&gt;
  <xsl:apply-templates/>
<;/xsl:template>

...would suffice.&nbsp; Unless you want it in some specific format?&nbsp; Please elaborate a little further and I'm sure someone can help you more.

Colin

On 8/12/07, Tommy Nordgren < tommy.nordgrencomhem.se">tommy.nordgrencomhem.se> wrote:
I need to find docbook stylesheets that can strip off xml markup, as
well as any content that is not plaintext.
Do someone on this list know of any such source.
Alternately, do some one know of any grammar checker for the english
language, hosted on Mac OS X,
that retains xml markup.

-------------------------------------
This sig is dedicated to the advancement of Nuclear Power
Tommy Nordgren
tommy.nordgrencomhem.se"> tommy.nordgrencomhem.se




---------------------------------------------------------------------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org">docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org">docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
user name
2007-08-13 01:40:26
Colin Shapiro wrote:
> Hi,
> 
> I'm not quite sure what you're asking for.  If you want
a stylesheet that
> simply returns the text from an XML document and does
nothing else, then I
> believe something as simple as:
> 
> <xsl:template match="/">
>   <xsl:apply-templates/>
> </xsl:template>
> 
> ...would suffice.  Unless you want it in some specific
format?  Please
> elaborate a little further and I'm sure someone can
help you more.


Yes for inlines. Not helpful for block elements?
lists become indented,
para's seperated by single line feed,
tables..... not easy.

etc.

That's my definition of 'plain text'.



regards

-- 
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk


------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
user name
2007-08-13 01:58:40
The best option I've found is to generate HTML and then
convert to text
using "links" tool, for example.

Camille.

Dave Pawson wrote:
> Colin Shapiro wrote:
>> Hi,
>>
>> I'm not quite sure what you're asking for.  If you
want a stylesheet that
>> simply returns the text from an XML document and
does nothing else,
>> then I
>> believe something as simple as:
>>
>> <xsl:template match="/">
>>   <xsl:apply-templates/>
>> </xsl:template>
>>
>> ...would suffice.  Unless you want it in some
specific format?  Please
>> elaborate a little further and I'm sure someone can
help you more.
> 
> 
> Yes for inlines. Not helpful for block elements?
> lists become indented,
> para's seperated by single line feed,
> tables..... not easy.
> 
> etc.
> 
> That's my definition of 'plain text'.
> 
> 
> 
> regards
> 


------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org
  
Re: Any source of Plain-text stylesheets?
user name
2007-08-13 04:01:17
Tommy Nordgren wrote:
> I need to find docbook stylesheets that can strip off
xml markup, as 
> well as any content that is not plaintext.


http://lynx.browser.org/

Lynx is a browser that is very simple.

Suggestion.

Generate the html using the docbook stylesheets.

Then use Lynx to download the file and save it as plain
text.
http://lynx.isc.org/lynx2.8.
5/lynx2-8-5/lynx_help/Lynx_users_guide.html#RemoteSource



(I seem to remember there was a command line option to load
the file,
then save to disk as plain text, but I can't find it)

HTH


regards

-- 
Dave Pawson
XSLT XSL-FO FAQ.
http://www.dpawson.co.uk


------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
country flaguser name
Germany
2007-08-13 04:08:30
Quoting Dave Pawson <davepdpawson.co.uk>:

> (I seem to remember there was a command line option to
load the file,
> then save to disk as plain text, but I can't find it)
>

This would be

lynx -dump somefile.html

However, as stripping the tags from a DocBook XML file is
not a  
DocBook-specific task, there should be general XML tools
that do just  
that. I just don't remember one.

regards,
Markus

-- 
Markus Hoenicka
markus.hoenickacats.de
(Spam-protected email: replace the quadrupeds with
"mhoenicka")
http://www.mhoenicka.de


------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
country flaguser name
Germany
2007-08-13 05:29:11
Quoting Dave Pawson <davepdpawson.co.uk>:

>> However, as stripping the tags from a DocBook XML
file is not a   
>> DocBook-specific task, there should be general XML
tools that do   
>> just that. I just don't remember one.
>
> Don't understand that. It surely *is* a docbook
specific task?
> E.g. One vocabulary uses code element as inline,
another uses
> it as a block level. Which do you choose?

I missed the start of the thread, but from what you quoted
of the  
original poster's message I did not gather that he was
looking for  
formatted plain text output (which would indeed be DocBook
specific,  
as you say).

regards,
Markus


-- 
Markus Hoenicka
markus.hoenickacats.de
(Spam-protected email: replace the quadrupeds with
"mhoenicka")
http://www.mhoenicka.de


------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


Re: Any source of Plain-text stylesheets?
country flaguser name
Sweden
2007-08-13 08:52:40
On 13 aug 2007, at 08.09, Colin Shapiro wrote:

> Hi,
>
> I'm not quite sure what you're asking for.  If you want
a  
> stylesheet that simply returns the text from an XML
document and  
> does nothing else, then I believe something as simple
as:
>
> <xsl:template match="/">
>   <xsl:apply-templates/>
>
> </xsl:template>
>
	This does part of what I want.
	It's necessary to add lines of the following type for every
element  
type I want to cut out:
	<xsl:template match="programlisting" />
	Of course, now I have another problem: Stripping out the
xml  
declaration in the output file.
As for what I want, it should be obvious from the second
part of my  
question: To check the English language grammar
embedded in DocBook markup. I can't do this directly from my
xml  
editor, because my grammar checking software mangles xml
markup
(Strips off data type declaration and drops end tags!!)
> ...would suffice.  Unless you want it in some specific
format?   
> Please elaborate a little further and I'm sure someone
can help you  
> more.
>
> Colin
>
> On 8/12/07, Tommy Nordgren <tommy.nordgrencomhem.se> wrote: I need  
> to find docbook stylesheets that can strip off xml
markup, as
> well as any content that is not plaintext.
> Do someone on this list know of any such source.
> Alternately, do some one know of any grammar checker
for the english
> language, hosted on Mac OS X,
> that retains xml markup.
>
> -------------------------------------
> This sig is dedicated to the advancement of Nuclear
Power
> Tommy Nordgren
> tommy.nordgrencomhem.se
>
>
>
>
>
------------------------------------------------------------
---------
> To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
> For additional commands, e-mail: docbook-apps-helplists.oasis- 
> open.org
>
>

------
What is a woman that you forsake her, and the hearth fire
and the  
home acre,
to go with the old grey Widow Maker.  --Kipling, harp song
of the  
Dane women
Tommy Nordgren
tommy.nordgrencomhem.se




------------------------------------------------------------
---------
To unsubscribe, e-mail: docbook-apps-unsubscribelists.oasis-open.org
For additional commands, e-mail: docbook-apps-helplists.oasis-open.org


[1-8]

about | contact  Other archives ( Real Estate discussion Medical topics )