Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

resize image icon to fit jlabel

ImageIcon imageIcon = new ImageIcon(new ImageIcon("icon.png").getImage().getScaledInstance(20, 20, Image.SCALE_DEFAULT));
label.setIcon(imageIcon);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #resize #image #icon #fit #jlabel
ADD COMMENT
Topic
Name
2+2 =