Am 13.03.22 um 10:14 schrieb Milamber:


On 13/03/2022 03:11, NaveenKumar wrote:
I was able to add the validate thread group action to the toolbar using the below properties in icons-toolbar.properties file.

But it is not picking up the custom icon from the `bin` directory. If I give the path as `org/apache/jmeter/images/toolbar/<SIZE>/document-new-4.png` it is displaying the icon and validate is working fine.

Is there a way to map the custom icon? Any inputs, please?


You need to put the icon files (3 sizes) in this directory:
./src/core/src/main/resources/org/apache/jmeter/images/toolbar/(22x22 32x32  48x48)/

After, build JMeter. You can find your new icons into /lib/ext/ApacheJMeter_core.jar

If I read the code at JMeterToolBar#getIconsMappings() right, you can add custom images for the buttons by providing your own properties file (look at icons-toolbar.properties for the format) and let the JMeter property jmeter.toolbar.icons point to it.

But even if it is working (haven't tested it), it feels cumbersome for third party plugin developers. If this is really the only way to extend the toolbar icons, it would make a good enhancement, don't you think?

And it seems, that you can use SVGs instead of PNGs, too.

Felix




toolbar=new,templates,open,save,|,undo,redo,cut,copy,paste,|,expand,collapse,toggle,|,test_start,test_start_notimers,test_stop,test_shutdown,validate_tg,|,test_clear,test_clear_all,|,search,search_reset,|,function_helper,help


validate_tg=validate,VALIDATE_TG,validate.png


Thank you

On 3/12/2022 12:15:20 PM, NaveenKumar <[email protected]> wrote:
Hi Team,

I am new to the JMeter core/plugin development ecosystem. I am trying to add a button to the toolbar.

Here is my repo [https://github.com/QAInsights/validate-thread-group]. But it is not displaying any option either in the menu or in the toolbar.

Could someone guide me, please?

Thank you!

Attachment: OpenPGP_0xEA6C3728EA91C4AF.asc
Description: OpenPGP public key

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

Reply via email to