How to add pictures

From OS.bee documentation
Jump to: navigation, search

Images for EnumCombobox

Using a EnumComboBox with images requires the creation and the storage of PNG-Images.

The images have to be from type PNG and the name has to be combined by the name of the enum class that hosts the combo box, the name of the enum literal and finally the postfix "image", e.g. TicketResolution.OPEN.image.png.

This images have to be stored with the corresponding theme icon subfolder within the bundle org.eclipse.osbp.themes in the git repository org.eclipse.osbp.vaadin.widgetset.

Path

org.eclipse.osbp.vaadin.widgetset/org.eclipse.osbp.themes/VAADIN/themes/<usedTheme>/icon/

Alternative Path

Alternatively you can create an own fragment bundle with the bundle org.eclipse.osbp.themes as host plug-in. Important is that you also create the corresponding theme icon subfolder and uses the required image file name as mentioned above and described below.

<ownThemeBundleName>/VAADIN/themes/<usedTheme>/icon/

(e.g. org.eclipse.osbp.mythemes/VAADIN/themes/osbp/icon/)

PNG File Name

<EnumClassName>.<EnumLiteral>.image.png

(e.g. MaritalStatus.MARRIED.image.png)

Creation of an own themes fragment

Using as bundle name org.eclipse.osbp.mythemes and as theme osbp:

  1. Select File menu item.

    Slide 1.png



  2. Go to New -> Other .

    Slide 2.png



  3. Select Plug-in Development.

    Slide 3.2.png



  4. Click on Fragment Projekt.

    Slide 4.2.png



  5. In Project name type: org.eclipse.osbp.mythemes.

    Slide 5.png



  6. Click on Next.

    Slide 6.png



  7. Click on Browse.

    Slide 7.png



  8. Click on Select a Plug-in text box.

    Slide 8.png



  9. Type in org.eclipse.osbp.th.

    Slide 9.png



  10. Select org.eclipse.osbp.themes (0.9.0.2017[...]).

    Slide 10.png



  11. Click on OK.

    Slide 11.png



  12. Click on Finish.

    Slide 12.png



  13. Click on Yes.

    Slide 13.png



  14. Right click on org.eclipse.osbp.mythemes

    Slide 14.png



  15. Go to New -> Folder

    Slide 15.png



  16. Type "VAADIN" in the Folder name text field.

    Slide 16.png



  17. Click on Finish.

    Slide 17.png



  18. Right click on VAADIN.

    Slide 18.png



  19. Go to New -> Folder.

    Slide 19.png



  20. Type in "themes".

    Slide 20.png



  21. Click on Finish.

    Slide 21.png



  22. Right click on themes.

    Slide 22.png



  23. Go to New -> Folder.

    Slide 23.png



  24. Type in "osbp".

    Slide 24.png



  25. Click on Finish.

    Slide 25.png



  26. Right click on osbp.

    Slide 26.png



  27. Go to New -> Folder.

    Slide 27.png



  28. Type in "icon".

    Slide 28.png



  29. Click on Finish.

    Slide 29.png



  30. You should end up with your screen looking similar to this.

    Slide 31.png



  31. Click on the icon folder.

    Slide 33.png



  32. This is what your screen should look like.

    Slide 34.png



Copyright Notice

All rights are reserved by Compex Systemhaus GmbH. In particular, duplications, translations, microfilming, saving and processing in electronic systems are protected by copyright. Use of this manual is only authorized with the permission of Compex Systemhaus GmbH. Infringements of the law shall be punished in accordance with civil and penal laws. We have taken utmost care in putting together texts and images. Nevertheless, the possibility of errors cannot be completely ruled out. The Figures and information in this manual are only given as approximations unless expressly indicated as binding. Amendments to the manual due to amendments to the standard software remain reserved. Please note that the latest amendments to the manual can be accessed through our helpdesk at any time. The contractually agreed regulations of the licensing and maintenance of the standard software shall apply with regard to liability for any errors in the documentation. Guarantees, particularly guarantees of quality or durability can only be assumed for the manual insofar as its quality or durability are expressly stipulated as guaranteed. If you would like to make a suggestion, the Compex Team would be very pleased to hear from you.

(c) 2016-2024 Compex Systemhaus GmbH