Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Computing > NZ Computing > OpenOffice HTML import

Reply
Thread Tools

OpenOffice HTML import

 
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      12-03-2008
I was looking at a way to automatically generate simple formatted text that
could be imported into OpenOffice.org 3 Writer, where I could tidy it up
and do some manual editing before printing it out.

Turns out that Ooo can open HTML documents, which are easy to generate from,
e.g. a Python script. On the downside, there is no support for tabs and
rulers in such documents. Indeed, tab characters are stripped on input.
However, if you write the HTML entity reference " ", this is converted
to a tab on input and not stripped. Not sure if this is a bug or a feature
in Ooo.

It is then easy to copy and paste text from the HTML document into a proper
Ooo Writer document, where you can define custom tab positions etc. And use
the format brush to quickly transfer settings from one paragraph to a bunch
of others.
 
Reply With Quote
 
 
 
 
David Goodwin
Guest
Posts: n/a
 
      12-03-2008
On Thu, 04 Dec 2008 00:03:43 +1300, Lawrence D'Oliveiro
<(E-Mail Removed)_zealand> wrote:

>I was looking at a way to automatically generate simple formatted text that
>could be imported into OpenOffice.org 3 Writer, where I could tidy it up
>and do some manual editing before printing it out.
>
>Turns out that Ooo can open HTML documents, which are easy to generate from,
>e.g. a Python script. On the downside, there is no support for tabs and
>rulers in such documents. Indeed, tab characters are stripped on input.
>However, if you write the HTML entity reference " ", this is converted
>to a tab on input and not stripped. Not sure if this is a bug or a feature
>in Ooo.
>
>It is then easy to copy and paste text from the HTML document into a proper
>Ooo Writer document, where you can define custom tab positions etc. And use
>the format brush to quickly transfer settings from one paragraph to a bunch
>of others.


Considered using TeX/LaTeX?
 
Reply With Quote
 
 
 
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      12-03-2008
In message <(E-Mail Removed)>, David Goodwin wrote:

> Considered using TeX/LaTeX?


No.
 
Reply With Quote
 
impossible
Guest
Posts: n/a
 
      12-04-2008
"David Goodwin" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> On Thu, 04 Dec 2008 00:03:43 +1300, Lawrence D'Oliveiro
> <(E-Mail Removed)_zealand> wrote:
>
>>I was looking at a way to automatically generate simple formatted text
>>that
>>could be imported into OpenOffice.org 3 Writer, where I could tidy it up
>>and do some manual editing before printing it out.
>>
>>Turns out that Ooo can open HTML documents, which are easy to generate
>>from,
>>e.g. a Python script. On the downside, there is no support for tabs and
>>rulers in such documents. Indeed, tab characters are stripped on input.
>>However, if you write the HTML entity reference " ", this is converted
>>to a tab on input and not stripped. Not sure if this is a bug or a feature
>>in Ooo.
>>
>>It is then easy to copy and paste text from the HTML document into a
>>proper
>>Ooo Writer document, where you can define custom tab positions etc. And
>>use
>>the format brush to quickly transfer settings from one paragraph to a
>>bunch
>>of others.

>
> Considered using TeX/LaTeX?


All these hoops to jump through!

That would explain the never-ending popularity of Microsoft Word, which
handles the task effortlessly. No problem with tabs or any other formatting.
It's really a shame that OO is still so klunky to work with after all this
time. But, seriously, the days when TeX/LaTeX could be considered even
remotely useful for producing anything besides math equations is long gone.

 
Reply With Quote
 
David Goodwin
Guest
Posts: n/a
 
      12-04-2008
On Thu, 04 Dec 2008 01:32:37 GMT, "impossible" <(E-Mail Removed)>
wrote:

>"David Goodwin" <(E-Mail Removed)> wrote in message
>news:(E-Mail Removed)...
>> Considered using TeX/LaTeX?

>
>All these hoops to jump through!
>
>That would explain the never-ending popularity of Microsoft Word, which
>handles the task effortlessly. No problem with tabs or any other formatting.
>It's really a shame that OO is still so klunky to work with after all this
>time. But, seriously, the days when TeX/LaTeX could be considered even
>remotely useful for producing anything besides math equations is long gone.


LaTeX still works just as well as it did 10 years ago and the
requirements of its target audience probably havent changed a whole
lot.

As for the original topic, it might be possible to just make a script
output in LaTeX allowing all the HTML, copying and pasting, etc, to be
eliminated. Any manual editing that is still required could be done in
a text editor, OOo Writer (which can import TeX files) or perhaps LyX.

Certainly if I ever needed to produce printable formatted text from a
script I would probably just do it that way. Could even automate the
printing if needed by sending the PostScript output directly to a
laser printer.
 
Reply With Quote
 
impossible
Guest
Posts: n/a
 
      12-04-2008
"David Goodwin" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> On Thu, 04 Dec 2008 01:32:37 GMT, "impossible" <(E-Mail Removed)>
> wrote:
>
>>"David Goodwin" <(E-Mail Removed)> wrote in message
>>news:(E-Mail Removed)...
>>> Considered using TeX/LaTeX?

>>
>>All these hoops to jump through!
>>
>>That would explain the never-ending popularity of Microsoft Word, which
>>handles the task effortlessly. No problem with tabs or any other
>>formatting.
>>It's really a shame that OO is still so klunky to work with after all this
>>time. But, seriously, the days when TeX/LaTeX could be considered even
>>remotely useful for producing anything besides math equations is long
>>gone.

>
> LaTeX still works just as well as it did 10 years ago and the
> requirements of its target audience probably havent changed a whole
> lot.
>
> As for the original topic, it might be possible to just make a script
> output in LaTeX allowing all the HTML, copying and pasting, etc, to be
> eliminated. Any manual editing that is still required could be done in
> a text editor, OOo Writer (which can import TeX files) or perhaps LyX.
>
> Certainly if I ever needed to produce printable formatted text from a
> script I would probably just do it that way. Could even automate the
> printing if needed by sending the PostScript output directly to a
> laser printer.


Or else just open the darn thing in Word and be done with it.

 
Reply With Quote
 
Lawrence D'Oliveiro
Guest
Posts: n/a
 
      12-04-2008
In message <(E-Mail Removed)>, David Goodwin wrote:

> Could even automate the printing if needed by sending the PostScript
> output directly to a laser printer.


I've done that. Or use Poppler to generate PDF.

The reason I wanted to generate an Ooo Writer document was to allow for
manual modifications before final printing.

I also experimented with running a Python script from within Ooo Writer,
making callbacks through the PyUNO interface to directly manipulate the
document. That did work, but it didn't seem easy to put up a dialog asking
the user for input, so I decided to stick with HTML interchange for now.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Convert html table to ods ( OpenOffice Spreadsheet ) HokBen ASP .Net 0 11-09-2006 03:46 AM
import db data into openoffice Ghido Python 0 09-26-2006 02:09 PM
to use import java.lang.* or import java.lang.Math or none at all? JPractitioner Java 13 02-24-2006 08:48 PM
XML Schema question - does "import" import elements? Vitali Gontsharuk XML 2 08-25-2005 07:33 PM
IMPORT STATIC; Why is "import static" file scope? Why not class scope? Paul Opal Java 12 10-10-2004 11:01 PM



Advertisments