Yay, that's actually cool :з So, I modified the code a bit to make it Pythonish. It doesn't print all existing properties though, but I modified it to print also at least every paragraph property. It is:
doc = desktop.loadComponentFromURL("file:///tmp/output.odt" ,"_blank", 0, ()) file = open('/tmp/log', 'w') for p in doc.PropertySetInfo.getProperties(): file.write("•••••••••••\n" + str(p).replace(',','\n') + "\n") enum = doc.Text.createEnumeration() while enum.hasMoreElements(): file.write("•••••••••••\n" + str(enum.nextElement().PropertySetInfo.getProperties()).replace(',','\n') + "\n") file.close() I am also replace commas with newlines to make it easier to differentiate (otherwise there're very long lines). It's 16150 lines from a simple test document btw ☺ 2015-08-20 13:35 GMT+03:00 Andreas Säger <ville...@t-online.de>: > Quick and dirty Basic routine to copy properties from obj1 to obj2: > >> Sub cloneProperties(obj1, obj2) >> dim a, i, s, v >> a() = obj1.PropertySetInfo.getProperties() >> on error goto resumeNextErr >> for each i in a() >> s = i.Name >> v = obj1.getPropertyValue(s) >> obj2.setPropertyValue(s,v) >> next >> exit sub >> resumeNextErr: >> resume next >> End Sub > > > > > -- > To unsubscribe e-mail to: users+unsubscr...@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 -- To unsubscribe e-mail to: users+unsubscr...@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