openoffice-api mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schmidt <joe...@j-m-schmidt.de>
Subject Re: [Q] using graphics in dialog in an extension
Date Wed, 18 Mar 2015 07:36:36 GMT
> From: Mathias Röllig [mailto:mroellig.news@gmx.net] 
> Sent: Tuesday, March 17, 2015 9:18 PM
> To: API AOO
> Subject: [Q] using graphics in dialog in an extension
> 
> Hello!
> 
> It is not a problem using graphics in a dialog. Simply adding 
> a graphics 
> control or adding icons to push buttons.
> 
> But how is the way if I want to provide such a dialog inside an 
> extension? Must every single graphic be loaded at startup, 

Yes 

> and if so, is 
> there a simple way for that?

--> Determine the location of extensin in the file system, example:

aService = GetDefaultContext().getByName("/singletons/com.sun.star.deployment.PackageInformationProvider")

bilderverzeichnis = aService.getPackageLocation("org.joesch.mottco") & "/mottco/"

(here where "org.joesch.mottco" is the extension ID and "mottco" the folder containing the
images in the extension)

-->Load the images


See as example:
http://calc-info.de/makros.htm#mottco

Greetings,
Jörg




---------------------------------------------------------------------
To unsubscribe, e-mail: api-unsubscribe@openoffice.apache.org
For additional commands, e-mail: api-help@openoffice.apache.org


Mime
View raw message