Recalculate Font on window resize
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
package edit2d
|
||||
|
||||
import b2 "vendor:box2d"
|
||||
import im "shared:odin-imgui"
|
||||
//import im "shared:odin-imgui"
|
||||
import mu "vendor:microui"
|
||||
import "core:slice"
|
||||
import draw "./draw"
|
||||
@@ -107,6 +107,7 @@ mu_interface_body_def_editor :: proc(interface: ^interface_state, def : ^engine_
|
||||
|
||||
}
|
||||
|
||||
/*
|
||||
interface_edit_static_index :: proc(interface:^interface_state, def: ^engine_entity_def) -> bool
|
||||
{
|
||||
curr_index := &interface.curr_static_index
|
||||
@@ -167,6 +168,7 @@ interface_edit_static_index :: proc(interface:^interface_state, def: ^engine_ent
|
||||
}
|
||||
return false
|
||||
}
|
||||
*/
|
||||
|
||||
mu_interface_edit_static_index :: proc(interface: ^interface_state, def : ^engine_entity_def) -> bool
|
||||
{
|
||||
@@ -184,6 +186,7 @@ mu_interface_edit_static_index :: proc(interface: ^interface_state, def : ^engin
|
||||
indexes := &level.relations[entity.index]
|
||||
|
||||
//if mu.slider()
|
||||
return true
|
||||
|
||||
|
||||
}
|
||||
@@ -383,12 +386,10 @@ interface_entity :: proc(interface: ^interface_state) -> bool
|
||||
//Flags
|
||||
for flag in engine_entity_flags_enum
|
||||
{
|
||||
contains := flag in def.entity_flags
|
||||
if im.Checkbox(fmt.ctprint(flag), &contains) do def.entity_flags ~= {flag}
|
||||
//contains := flag in def.entity_flags
|
||||
//if mu.checkbox(fmt.tprint(flag), &contains) do def.entity_flags ~= {flag}
|
||||
}
|
||||
|
||||
im.Separator()
|
||||
|
||||
|
||||
if .ACTIVE in mu.begin_treenode(&interface.state.mu_ctx, "Body Def")
|
||||
{
|
||||
@@ -402,14 +403,13 @@ interface_entity :: proc(interface: ^interface_state) -> bool
|
||||
mu.end_treenode(&interface.state.mu_ctx)
|
||||
}
|
||||
|
||||
im.Separator()
|
||||
|
||||
|
||||
if .ACTIVE in mu.begin_treenode(&interface.state.mu_ctx, "Static Index")
|
||||
{
|
||||
ret |= interface_edit_static_index(interface, def)
|
||||
//ret |= interface_edit_static_index(interface, def)
|
||||
}
|
||||
|
||||
/*
|
||||
if .CHAIN in def.entity_flags
|
||||
{
|
||||
im.InputInt("Body Count", &def.body_count)
|
||||
@@ -420,6 +420,7 @@ interface_entity :: proc(interface: ^interface_state) -> bool
|
||||
interface_edit_rev_joint_minimal(&def.rev_joint)
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
return !compare_engine_entity_def(def^, def_old) || ret
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user