diff --git a/main.cpp b/main.cpp index e64c3ca..23e1c46 100644 --- a/main.cpp +++ b/main.cpp @@ -728,6 +728,19 @@ static void render() { ge::views_reset_visibility(g_app); ge::views_apply_visibility(g_app); + // Reaplica types.yaml + atlas. Sin esto, despues de cualquier + // mutacion los tipos pierden color/shape/icon (todo nodo vuelve a + // circulo gris). Issue: al promover desde tableview el Table + // dejaba de ser cuadrado. + if (!g_app.parsed_types.entities.empty() || + !g_app.parsed_types.relations.empty()) { + std::vector cps = ge::apply_types_yaml(g_graph, g_app.parsed_types); + if (g_atlas) { graph_icons_destroy(g_atlas); g_atlas = nullptr; } + g_atlas = ge::build_icon_atlas(cps); + g_atlas_bound = false; + g_gpu_dirty = true; + } + // Refresh Table node counts (issue 0010). ge::tableview_refresh_counts(g_input.uri, &g_app.table_node_counts);