Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Take a lazy weekend and walk through
http://docs.python.org/tutorial/index.html
All you need is a text editor and a shell. A Python capable text editor
provides some window where you can dump debugging output. Linux users who
are familiar with vim or emacs already found their personal IDE for Python.

Regarding the office suite, all you need is a slightly deeper understanding
of the context you are coding in:
http://www.openoffice.org/udk/python/python-bridge.html 
1) Macros called from within the office:
ThisComponent=XSCRIPTCONTEXT.getDocument() 
2) Contacting a running office on port 2002 from your Python program and
getting all the office objects to start with:
import uno
localContext = uno.getComponentContext()
resolver = localContext.ServiceManager.createInstanceWithContext(
    "com.sun.star.bridge.UnoUrlResolver", localContext 
)
ctx =
resolver.resolve("uno:socket,host=localhost,port=2002;urp;StarOffice.ComponentContext"
)
oDesktop=ctx.ServiceManager.createInstanceWithContext("com.sun.star.frame.Desktop",ctx)
oFrame=oDesktop.getCurrentFrame()
oView=0Frame.getController()
ThisComponent=0View.getModel()

http://user.services.openoffice.org/en/forum/viewtopic.php?f=20&t=22431
Forum topic about Macro IDE for Python 
http://user.services.openoffice.org/en/forum/viewtopic.php?f=45&t=22904&p=104656
Emacs + Python + Office 
http://www.oooforum.org/forum/viewtopic.phtml?t=59534 Cell functions in
Python scripts (called through Basic) 
http://www.oooforum.org/forum/viewtopic.phtml?t=59580 Desparately missing
MsgBox in Python 
Search anything python related by author DannyB on oooforum.org 

--
View this message in context: 
http://nabble.documentfoundation.org/Python-info-for-a-new-learner-tp3613594p3621653.html
Sent from the Users mailing list archive at Nabble.com.

-- 
For unsubscribe instructions e-mail to: users+help@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

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.