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

python - Installing PyDev in eclipse is failed -

PHP OOP-based login system -

c# - Nested Internal Class with Readonly Hashtable throws Null ref exception.. on assignment -