Fix anchor problems
This commit is contained in:
parent
26360d0e6a
commit
3eb9cdf1ec
|
|
@ -117,7 +117,7 @@ func _unhandled_input(event : InputEvent) -> void:
|
||||||
#---------- construction de l'interface ----------
|
#---------- construction de l'interface ----------
|
||||||
|
|
||||||
func _build_ui() -> void:
|
func _build_ui() -> void:
|
||||||
set_anchors_preset(Control.PRESET_FULL_RECT)
|
set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT) #le node est deja dans l'arbre : il faut aussi remettre les offsets a zero
|
||||||
|
|
||||||
var bg := ColorRect.new()
|
var bg := ColorRect.new()
|
||||||
bg.color = Color(0, 0, 0, 0.8)
|
bg.color = Color(0, 0, 0, 0.8)
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ func _unhandled_input(event : InputEvent) -> void:
|
||||||
#---------- construction de l'interface ----------
|
#---------- construction de l'interface ----------
|
||||||
|
|
||||||
func _build_ui() -> void:
|
func _build_ui() -> void:
|
||||||
set_anchors_preset(Control.PRESET_FULL_RECT)
|
set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT) #le node est deja dans l'arbre : il faut aussi remettre les offsets a zero
|
||||||
|
|
||||||
var bg := ColorRect.new()
|
var bg := ColorRect.new()
|
||||||
bg.color = Color(0, 0, 0, 0.8)
|
bg.color = Color(0, 0, 0, 0.8)
|
||||||
|
|
|
||||||
|
|
@ -137,7 +137,7 @@ func _unhandled_input(event : InputEvent) -> void:
|
||||||
#---------- construction ----------
|
#---------- construction ----------
|
||||||
|
|
||||||
func _build_ui() -> void:
|
func _build_ui() -> void:
|
||||||
set_anchors_preset(Control.PRESET_FULL_RECT)
|
set_anchors_and_offsets_preset(Control.PRESET_FULL_RECT) #le node est deja dans l'arbre : il faut aussi remettre les offsets a zero
|
||||||
mouse_filter = Control.MOUSE_FILTER_IGNORE
|
mouse_filter = Control.MOUSE_FILTER_IGNORE
|
||||||
|
|
||||||
_root_box = MarginContainer.new()
|
_root_box = MarginContainer.new()
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue