How do I add an icon as a classpath resource to an SWT window created with WindowBuilder?

前端 未结 6 594
名媛妹妹
名媛妹妹 2021-02-07 09:48

I\'m trying to add an external icon from an *.ico file to a window that I\'m creating using the WindowBuilder design window. I can select the shell, which brings up an \"image\"

6条回答
  •  有刺的猬
    2021-02-07 10:17

    The solution I find to be working is to create a jar containing your images and add it to your class path. Then you will be able to choose them from the dialog in your second screen shot.

    I remember this used to work with directories that are in your build path. Now it seems to be forced to be in a jar package.

提交回复
热议问题