java - What is the point of overriding the getInsets() method? -


i'm looking @ documentation javax.swing.jcomponent, , method stuck out me because trying create subclass of type. there point in overriding getinsets()? purpose of method when have getpreferredsize()?

getinsets defines space can taken content, borders, is, generally, added preferredsize , offsets position (translates) of graphics context, ensure actual content painted instead insets.

personally, unless intend prevent modifying state of components borders or thinking providing margins of sort, i'd leave alone (and not override it)


Comments

Popular posts from this blog

jquery - How do you format the date used in the popover widget title of FullCalendar? -

Bubble Sort Manually a Linked List in Java -

asp.net mvc - SSO between MVCForum and Umbraco7 -