Added show rulers & guides in the View menu

This commit is contained in:
OverloadedOrama 2019-12-03 02:30:38 +02:00
parent 5ffd0ecf6a
commit 70bd1dde43
4 changed files with 27 additions and 1 deletions

View file

@ -55,6 +55,8 @@ func _draw() -> void:
draw_line(Vector2(position.x + RULER_WIDTH, RULER_WIDTH * 0.66), Vector2(position.x + RULER_WIDTH, RULER_WIDTH), Color.white)
func _on_HorizontalRuler_pressed() -> void:
if !Global.show_guides:
return
var mouse_pos := get_local_mouse_position()
if mouse_pos.x < RULER_WIDTH: #For double guides
Global.vertical_ruler._on_VerticalRuler_pressed()