[libreoffice-users] Re: How to change the layout of document via PyUNO/UNO

2011-10-21 Thread Alex Thurgood

Le 19/10/2011 10:39, Gabriel Monnerat a écrit :

Hi,


Yes, sure. I am trying to convert one html document to odt. But, when
I open this document, he is using the Web Layout.


You write after convert document :
- which document ?
- which format(s) ?
- how are you converting it ?


I am converting using PyUNO through my tool Cloudooo. You can see code here:

http://git.erp5.org/gitweb/cloudooo.git

And how the document is converted here:

http://git.erp5.org/gitweb/cloudooo.git/blob/HEAD:/cloudooo/handler/ooo/helper/unoconverter.py


Also, what do you mean by another layout ?


Yes, I want open the document after the document of html to odt in
Print Layout.



This sounds like the web layout bug introduced sometime in the 3.4 
development. As far as I know this hasn't been fixed yet possibly 
because the bug report in question refers to Base Forms. If you have 
discovered a UNO dependency where the bug also appears (and maybe this 
is the root cause) then it would be worthwhile raising this on the 
developer mailing list.



Alex


--
For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



[libreoffice-users] Re: How to change the layout of document via PyUNO/UNO

2011-10-19 Thread Gabriel Monnerat
Hello,

 Since Gabriel and I are both working on similar tools, I think I know what he
 needs. We both have written a tool to convert documents using LibreOffice
 import and export filters. We use PyUNO to open and save documents and
 during this 'conversion' problems have been reported that the page format
 (eg. A4) is not retained.

 My understanding is that either the original document has no paper format 
 configured,
 or it does not fit the expected dimensions. So the question is, how can we
 set (enforce) the correct page dimensions before exportingto another
 document format using PyUNO ?

I have found some example code in Basic, however I couldn't transcode it to
 working Python code :-

/


Do you have the link to the example code in Basic? I would like to see :)

Regards,

-- 
Gabriel M. Monnerat

-- 
For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



[libreoffice-users] Re: How to change the layout of document via PyUNO/UNO

2011-10-19 Thread Gabriel Monnerat
Hello,

 Hi Gabriel,

 You might need to give us a bit more detail about what it is exactly
 that you are trying to do ?

Yes, sure. I am trying to convert one html document to odt. But, when
I open this document, he is using the Web Layout.

 You write after convert document :
 - which document ?
 - which format(s) ?
 - how are you converting it ?

I am converting using PyUNO through my tool Cloudooo. You can see code here:

http://git.erp5.org/gitweb/cloudooo.git

And how the document is converted here:

http://git.erp5.org/gitweb/cloudooo.git/blob/HEAD:/cloudooo/handler/ooo/helper/unoconverter.py

 Also, what do you mean by another layout ?

Yes, I want open the document after the document of html to odt in
Print Layout.




-- 
Gabriel M. Monnerat

-- 
For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



[libreoffice-users] Re: How to change the layout of document via PyUNO/UNO

2011-10-17 Thread Alexander Thurgood
Le 17/10/11 13:17, Gabriel Monnerat a écrit :

Hi Gabriel,

 Hello,
 
 I would like to know that is possible change the document layout via
 UNO because after convert the document it is not opened in standard
 layout(is opening in another layout).
 
 So, is possible change the layout and define it on document?

You might need to give us a bit more detail about what it is exactly
that you are trying to do ?

You write after convert document :
- which document ?
- which format(s) ?
- how are you converting it ?

Also, what do you mean by another layout ?


Alex


-- 
For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted



Re: [libreoffice-users] Re: How to change the layout of document via PyUNO/UNO

2011-10-17 Thread Dag Wieers

On Mon, 17 Oct 2011, Alexander Thurgood wrote:


Le 17/10/11 13:17, Gabriel Monnerat a écrit :


I would like to know that is possible change the document layout via
UNO because after convert the document it is not opened in standard
layout(is opening in another layout).

So, is possible change the layout and define it on document?


You might need to give us a bit more detail about what it is exactly
that you are trying to do ?

You write after convert document :
- which document ?
- which format(s) ?
- how are you converting it ?

Also, what do you mean by another layout ?


Since Gabriel and I are both working on similar tools, I think I know what 
he needs. We both have written a tool to convert documents using 
LibreOffice import and export filters. We use PyUNO to open and save 
documents and during this 'conversion' problems have been reported that 
the page format (eg. A4) is not retained.


My understanding is that either the original document has no paper format 
configured, or it does not fit the expected dimensions. So the question 
is, how can we set (enforce) the correct page dimensions before exporting 
to another document format using PyUNO ?


I have found some example code in Basic, however I couldn't transcode it 
to working Python code :-/


PS The tool I am working on is available from:

http://github.com/dagwieers/unoconv

Kind regards,
--
-- dag wieers, d...@wieers.com, http://dag.wieers.com/
-- dagit linux solutions, i...@dagit.net, http://dagit.net/

[Any errors in spelling, tact or fact are transmission errors]
--
For unsubscribe instructions e-mail to: users+h...@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted