Hacking OpenOffice
prostoalex writes "Peter Sefton appreciates OpenOffice Writer's open and documented XML format and hence tries to customize and configure OO Writer to his own liking. In the article on XML.com he plays with OpenOffice XML, introduces an XSTL style sheet to a Writer document, creates a keyboard shortcut for applying his own style, and creates a macro."
Creates his *own* macro, eh? WOW!
What a fucken joke.
That's a lot you can do with xsltproc and unzip - but xsltproc is way to neat to call it a hack.1 0/perl/perl.html
Most day-to-day manipulations of Open-Office-Documents can easiely be done with perl:
At the bottom of the article (german) is a listing (Perl)
http://www.linux-magazin.de/Artikel/ausgabe/2004/
069 my $oo_output = File::Temp->new(
070 TEMPLATE => 'ooXXXXX',
071 DIR => '/tmp',
072 SUFFIX => '.sxw',
073 UNLINK => 1,
074 );
075
076 $doc->save($oo_output->filename);
God bless open standards.
Three men walk into a bar. They all got concussions.
Frodo twirled a lock of brown between two slender, pale fingers
unconsciously. He was staring at Samwise, a younger hobbit, who was
playing in the garden. His knees were dirty and his hands were covered in
the filthy ground, but Frodo couldn't keep his eyes off the boy. Sweat
trickled down the hobbit's brow and he paused, leaning heavily on one
grubby hand, to wipe at his forehead with a dirt-smearing handkerchief he
dug out of one of his trouser pockets. Frodo found himself indiscreetly
watching the hobbit play with his toy shovel and pat piles of dirt into small
mounds as he sat in the flowerbed. Muscles ripped like waves of an ocean,
sunlight shining off his damp hair and bare skin. His cheeks were red and
a smile was upon his lips as he worked the dirt, staring at his creation with
small, dark blue eyes.
Snapping out of his trance, Frodo noticed his mouth was hanging
open and he shut it immediately. His lips were wet; each breath he drew
was heavier than the last. He rubbed his sweaty palms on his pants and
shut the book that lay sprawled in his lap. It wouldn't do him any good to
read now. His eyes would not focus, nor would his mind. Nothing was
going right. All he could think about was Samwise Gamgee and his
beautiful, deep eyes. They were the color of the sea, and the sky and every
emotion in a single flash of brilliant paints.
His thoughts were consumed by the hobbit and he felt his body
growing warm, especially his groin. He tried to think of something else,
more familiar, but each thing led him back to Sam's body. The beautiful,
bare skin of his forearms and legs taunted Frodo and caused his groin to
tighten. The hobbit blushed bright red and pressed his hands to his cheeks,
trying to cool his face. Much to his horror he felt his cock harden and
press against his trousers unrelentingly.
Frodo felt his body began to throb, but he was confused. This had
never happened before and he didn't know if it was natural. Was his body
supposed to be swelling and throbbing? Perhaps he had injured himself
how--but what had he done? Frodo couldn't remember having done
anything that might have injured that part of his body. Maybe he had
caught a rare and deadly disease! He started to panic, before he
remembered something he had heard one of the other hobbit lads talking
about. When it gets like that, I just give it a quick yank, unless there is a
hobbit girl around. The comment had been followed by a lot of laughter
from the other hobbits, but Frodo had just felt like he was being left out of
a big secret.
What did a hobbit girl have to do with anything? Sure, they were
pretty and kind, but he didn't think they were the same as his Sam.
His groin stared to ache and he felt as if he might explode with a
million feelings. In his gut he felt awful, but it was exciting, feeling like
had did. His hand found his belt bucket and unfastened it. Then, clumsily,
he unbuttoned his pants and let them drop to the ground. Sitting alone, in
his room, Frodo slowly laid his hand on his cock. When nothing bad
happened he drew a finger across it in a silky, cool line. A small shiver
shot up his spine and he encircled the member with his hand and moved it
lightly at first. He started to feel happier, his excitement peaking as his
hand traveled quicker with each stroke. Suddenly, in a burst of warmth,
Frodo released into his hand, and moaned bitterly, wishing the pleasure
would not leave.
The door flew open at that moment and Bilbo came in, busily
searching for his pipe he had misplaced. Frodo quickly got up and tried to
button his pants in a quick movement, without his uncle noticing. Bilbo
looked up at Frodo at that exactly instant and started to ask,
"Have you seen my pipe?" but he stopped speaking in mid-
sentence and stared at Frodo. His nephew looked anywhere, except at
Bilbo. He stared at the floor, the ceiling, the window and the no
I fart on this weak, girly article. Real men use AbiWord. Or emacs.
Clippy: I see that you're making a XSTL style sheet to a Writer document. You can't do that with Word. Would you like to:
-> Learn about XSTL?
-> Learn about OpenOffice Writer (boo hiss)?
-> Learn about macros?
-> What is style by Trading Spaces?
-Teiresias
That should be XSLT, not XSTL.
That's pretty slick.
It's neat to see something like this being done. It really shows the true versatility of open standards.
Perhaps more projects like this will open up some eyes to the fact that open standards really do have practical value.
Isn't that supposed to be XSLT? Or is there a technology called XSLT and one called XSTL??
The right to offend is far more important than the right not to be offended. (Rowan Atkinson)
You'd think that these people talking about creating usable templates and proper layouting would at least create a site that doesn't require me to maximize my browser window (at least in the horizontal direction. Seriously, not everybody is viewing everything at 1600px width.
This is old hat. Binary XML is the new way forward. You can embed apps and pif,src, and bat and exe files now into binary XML using Microsoft Word on XP and run them with Active X and .NET and Java. Microsoft invented java and internet.
and xml
The Army reading list
Here at work many of the users are switched over to OO.O except for the producers in the video department.
why? there are no scriptwriting tools for OO.o like there are for Word 97.
there are auto scriptwriter formatting plugins and two column scriptwriting templates and tools that make their life easy.
unfortunatlly nobody has released for sale or even attempted to write the equiliviant for OO.o.
we paid $29.95 to $49.95 each machine for those scriptwriting toolkits, and would happily pay the same for OO.o equiliviants.
but nobody is interested in making them.
Let alone a version of any wordprocessor geared to Scriptwriting. I know there will never ever be a "final draft" for linux released or even an open source project like it ever started. But I at least hold out some hope for scriptwriting tools for Open Office.org to come into existance someday.
Do not look at laser with remaining good eye.
I created them for an early version but my changes were not compatible with more recent versions.
The default key bindings drive me nuts.
What would it take to get emacs bindings into the release?
they could introduce a hack to remove all the busted-ugly icons and user interface.
(I'm not trolling, I use it; I'd just like to see it get a +1 pretty modifier.)
Real man uses [La]TeX!
Athletic Scholarships to universities make as much sense as academic scholarships to sports teams.
Microsoft Office Documents are in XML !!! You can play with MSXML (with its xslt proc) if you want, even in vba =o)... Sure, when MS will understand that the first XML feature is to be HUMAN-READABLE ??? Anyone seen or worked on theses crappy "open" Office 2003 XSD, and did not try to commit suicide or murder ? Guns don't kill people, MS Do
Has any one used the COM Automation Interface much? I've read the specs and it seems similar to MS Office, but is any one seeing any improvements by using OO instead of MS Office. I've done quite a bit of programming with Word and Excel, and would love to move them over to OO so I could bundle it with our app.
I had to remove OOo from my home box last night. I needed the disk space back. Why does a office suite on a Linux box have to take up a gig of disk?!
- Output is ugly compared even to Word and definitely compared to TeX. When I do a numbered list, the width of the number changes where the text begins, and you end up with a jagged left edge.
- The help assistant guy comes up and pretends to be Clippit even when you don't have any help files installed, so when you click on him it essentially does a 404.
- Autocomplete for your words. It's really getting on my nerves and I can't find how to shut it off.
I'm sure I have others that I'm just not thinking of right now.guess how long people will develop a firefox/mozilla extension to view the openoffice.org document directly in firefox/mozilla?
guess how long nvu/mozilla will have the ability to export and import oo.org format?
guess how long a CMS system based on the oo.org format will emerge?
God, I am to busy to write posts to slashdot.org, I don't have any time to do those stuff.
There is a spark in every single flame bait point.
I wrote a PHP script to do this a while back, here's my post about it:
0 29 828
i ter#results) .
http://slashdot.org/comments.pl?sid=79566&cid=7
It took a OpenOffice Writer file, unzipped it, and replaced specific text with data from my database. It wasn't too difficult, and allowed me to create Template Documents that already had information inside it.
I haven't really used it though, since everyone was happy with PDF files and I use the Pear Class for generating spreadsheets in Excel (http://pear.php.net/package/Spreadsheet_Excel_Wr
I'm sure I'll end up using the script in the future, especially for generating bids, letters, reports, etc.
---
Brandon Petersen
Get Firefox!
Why not go ahead and fix global changes to all highlighted cells? This is a bug in need of fixing. OTOH, as has been said, it's definitely a plus that this can even be done (re: hacking).
reinvent it pretty damn sweetly
Check out Arch Linux, a distro targeted to 'competent users' that has a wonderful package manager. Dependencies are built into packages. Optional dependencies are usually not listed, and even if they are, you can use the Arch Build System to make your own package from the Arch stock PKGBUILD.
I installed the openoffice package and couldn't figure out why it wouldn't run until I realized I hadn't installed the i18n-en files.
Please stop stalking me, bro.
I really meant to hit preview...
What was missing was the openoffice-en package (not i18n-en files... BAD GEEK! BAD!). And I added openoffice-spell-en. I think it's a little under 100MB total? A little bloaty for my tastes, but it is an office suite.
Please stop stalking me, bro.
Last time I check, OOO maintainers are playing the 'we don't need stinking grammar checker' politics on this issue. For the few tools that do (eg: Link Grammar, Queerqueq), they never talk with each other.
OK, for a living I migrate companies from Microsoft to FOSS, be it migrating servers, databases, directories or MSOffice to OO
My biggest hurdle is convincing people that just because something is "different", its not "hard"... it's just different.
The problem I see here is that an Office Productivity Package should be easy to use; have you ever created a template in MS Office, click an icon. However to create a template in Open Office, you need to hack XML.
THIS is where Open Office (and its use of Open Standards) fails. Users (even power users) are going to have one look at an XML sheet and want to go back to MS.
Yes, XML is the standard, but it should still have a "pretty" GUI for 99% of the people who are going to use it.
"I fart on this weak, girly article. Real men use AbiWord. Or emacs."
Pfft. Real Men don't use computers, but do it all in their head. And yes, they do speak printer.
Every time I try an OOo release, it's too slow on my PIII/850/kernel2.4.24 . Like waiting more than a few seconds for an "Open" dialog to start (sometimes a minute!). Has anyone tweaked the performance under the hood?
--
make install -not war
Would it be possible, without perpetual zipping and unzipping to use an XML/RSS file as a datasource, and create a simple and easy RSS editor?
Someth1ng done
http://www.rafb.net/paste/results/OqhmkL56.html
feh, too much work. i'd rather distract myself with emacs.
Comment removed based on user account deletion
And there's no porn or anti-Shrub results in any of them, at least on the first page.
In general, if you're not getting the results you want you need to disambiguate your search by adding additional terms. Just searching for "latex" will get you porn; searching for "latex + [some typesetting-related word]" will get you LaTeX stuff. The same applies for other things; "apple computer" will get you stuff about Macs while "apple fruit" will get you stuff about apples.
"[Regarding the 'cloud,'] ownership was what made America different than Russia." -- Woz
Hi all -
... )
e xcel.html
e ls_s.html
Just thought I'd mention a great site for those who are still stuck with Excel, and who need to somehow programmatically manipulate "bitsy" Excel worksheets, and who must do so **remotely - in a Unix/Linux environment**. So, you can't use any local Windows-based tools.
( By "bitsy", I mean sheets with complex layout - a bit here, some more stuff over there, and so on).
Here are the URLs (and **believe me**, these are worth a visit
http://ewbi.blogs.com/develops/2004/12/normalize_
http://ewbi.blogs.com/develops/2005/01/create_exc
If you have a **desperate need** to manipulate/transform/rearrange data in Excel (and you need to do so in Unix/Linux), check out the URLs above. They show how to translate to-and-from Excel's XML format. Awesome stuff!
Here is the PHP Class that I've been refering to. It's very basic proof of concept. I'm sure there are many elegant improvements that could be made:
h ps
http://brandonpetersen.com/code/Generate_Report.p
Hope this is useful.
Brandon Petersen, http://brandonpetersen.com/
Get Firefox!