mirror of
https://github.com/Relintai/uml_generator.git
synced 2024-11-20 10:57:28 +01:00
Better class control sizing.
This commit is contained in:
parent
843ece8db8
commit
6bb14cb660
@ -5,6 +5,8 @@
|
||||
[node name="ClassControl" type="PanelContainer"]
|
||||
margin_right = 42.0
|
||||
margin_bottom = 30.0
|
||||
size_flags_horizontal = 4
|
||||
size_flags_vertical = 4
|
||||
script = ExtResource( 1 )
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="."]
|
||||
|
@ -82,9 +82,8 @@ func _process_state_next(delta):
|
||||
content = content.replace("\r\n", "\n")
|
||||
var lines : Array = content.split("\n")
|
||||
|
||||
var current_content_container : VBoxContainer = VBoxContainer.new()
|
||||
current_content_container.set("custom_constants/separation", 0)
|
||||
_content_container.add_child(current_content_container)
|
||||
var current_content_container : VBoxContainer = create_sub_content_container()
|
||||
|
||||
var in_class : bool = false
|
||||
var current_class_access_modifier : int = AccessModifierState.ACCESS_MODIFIER_PRIVATE
|
||||
var class_control : Control = null
|
||||
@ -100,9 +99,8 @@ func _process_state_next(delta):
|
||||
continue
|
||||
|
||||
if l.begins_with("new_column"):
|
||||
current_content_container = VBoxContainer.new()
|
||||
current_content_container.set("custom_constants/separation", 0)
|
||||
_content_container.add_child(current_content_container)
|
||||
current_content_container = create_sub_content_container()
|
||||
|
||||
continue
|
||||
|
||||
if l.begins_with("inherit"):
|
||||
@ -171,3 +169,11 @@ func clear_content():
|
||||
for c in _content_container.get_children():
|
||||
c.queue_free()
|
||||
_content_container.remove_child(c)
|
||||
|
||||
func create_sub_content_container():
|
||||
var content_container : VBoxContainer = VBoxContainer.new()
|
||||
content_container.set("custom_constants/separation", 0)
|
||||
content_container.alignment = BoxContainer.ALIGN_CENTER
|
||||
_content_container.add_child(content_container)
|
||||
|
||||
return content_container
|
||||
|
Loading…
Reference in New Issue
Block a user