Issue 74525 - com.sun.star.XStyle - need some enhancement
Summary: com.sun.star.XStyle - need some enhancement
Status: CONFIRMED
Alias: None
Product: App Dev
Classification: Unclassified
Component: api (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: All All
: P3 Trivial
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-02-14 09:52 UTC by Oliver Brinzing
Modified: 2013-02-24 21:06 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Oliver Brinzing 2007-02-14 09:52:18 UTC
Hi,

I am missing some methods for the css.XStyle interface:

- hasChildrenSytyles()
- getChildrenStyles()

this would make it easier to change style trees, or deploy custom
gui applications (e.g. oo extensions) for handling styles ...

- cloneStyle()
- cloneChildrenStyles()

this would allow copying whole style trees e.g.

- Default
  -Custom Text 10pt
   - Custom Text 10pt bold
   - Custom Text 10pt outline

copy  -Custom Text 12pt
       - Custom Text 12pt bold
       - Custom Text 12pt outline

result:

- Default
  -Custom Text 10pt
   - Custom Text 10pt bold
   - Custom Text 10pt outline
  -Custom Text 12pt
   - Custom Text 12pt bold
   - Custom Text 12pt outline

the style names could be changed by traversing the clone before 
inserting it into the styles, e.g. setting a postfix after all names
to avoid duplicates ..

this feature could also be included into the stylist ...

and last: Why don't we have a global styles container inside oo, where a
          user can import/export styles ? This would be easier as copying
          styles between documents ...

I also want to point to the following issues:

http://qa.openoffice.org/issues/show_bug.cgi?id=12339
http://qa.openoffice.org/issues/show_bug.cgi?id=15889

regrads 

Oliver
Comment 1 jsc 2007-02-16 17:02:12 UTC
jsc -> tl: can you please check this
Comment 2 thomas.lange 2007-02-19 08:38:05 UTC
.
Comment 3 thomas.lange 2007-02-19 08:41:22 UTC
Since style are not structured as trees internally as well this can bot be done
right away. Thus setting the target to OOolater.

If you like to get your style trees anyway you can do so yourself though:
You just need to iterate over all the styles and ask each of 'em for their
parent, with this information you can build those style trees.