diff options
author | Juan Linietsky <reduzio@gmail.com> | 2015-02-10 23:53:04 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2015-02-10 23:53:04 -0300 |
commit | d22b256f0841a0ff97f45c5a11aeccd7658b79fa (patch) | |
tree | 40207cf70b78f691c8e59210c31fc17674d0b398 /scene | |
parent | 86786588759bea9a9128f15a25c8d7145aeecbd5 (diff) |
customizable content margin in styleboxes
Diffstat (limited to 'scene')
-rw-r--r-- | scene/resources/style_box.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scene/resources/style_box.cpp b/scene/resources/style_box.cpp index 316b5e91eb..ca4bd3d253 100644 --- a/scene/resources/style_box.cpp +++ b/scene/resources/style_box.cpp @@ -85,6 +85,12 @@ void StyleBox::_bind_methods() { ObjectTypeDB::bind_method(_MD("draw"),&StyleBox::draw); + ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/left", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_LEFT ); + ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/right", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_RIGHT ); + ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/top", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_TOP); + ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/bottom", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_BOTTOM ); + + } StyleBox::StyleBox() { |