From 1a70de0efe2a4cabfc1fa27c0d264cc136feaf0c Mon Sep 17 00:00:00 2001 From: Pan7 Date: Sun, 4 Oct 2015 10:53:05 +0200 Subject: [PATCH 1/5] Angle arrow for entities with angle and fixed size --- radiant/eclass_def.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/radiant/eclass_def.cpp b/radiant/eclass_def.cpp index 7db391c5..5cf5c2c0 100644 --- a/radiant/eclass_def.cpp +++ b/radiant/eclass_def.cpp @@ -250,6 +250,12 @@ eclass_t *Eclass_InitFromText( char *text ){ ) { e->nShowFlags |= ECLASS_ANGLE; } + for ( i = 0 ; i < MAX_FLAGS ; i++ ) + { + if ( e->flagnames[i] && e->flagnames[i][0] != 0 && strcmpi( e->flagnames[i], "angle" ) && e->fixedsize ) { + e->nShowFlags |= ECLASS_ANGLE; + } + } if ( strcmpi( e->name, "path" ) == 0 ) { e->nShowFlags |= ECLASS_PATH; } From c9611524088411874d7063b1c829eaa0555e9d15 Mon Sep 17 00:00:00 2001 From: Mateos81 Date: Mon, 5 Oct 2015 23:11:24 +0200 Subject: [PATCH 2/5] Step 1: Numeric Keypad changes Grid Size --- radiant/mainframe.cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/radiant/mainframe.cpp b/radiant/mainframe.cpp index 33b94d1a..62c09a35 100644 --- a/radiant/mainframe.cpp +++ b/radiant/mainframe.cpp @@ -20,7 +20,7 @@ */ // -// Main Window for Q3Radiant +// Main Window for GtkRadiant // // Leonardo Zide (leo@lokigames.com) // @@ -44,7 +44,7 @@ extern "C" { #include "patchdialog.h" #include "filters.h" -// use this to verbose what happens with the beyboard +// use this to verbose what happens with the keyboard #ifdef _DEBUG // #define DBG_KBD #endif @@ -162,15 +162,25 @@ SCommandInfo g_Commands[] = {"CameraStrafeRight", GDK_period, 0, ID_CAMERA_STRAFERIGHT, "menu_camera_straferight"}, {"CameraStrafeLeft", GDK_comma, 0, ID_CAMERA_STRAFELEFT, "menu_camera_strafeleft"}, {"ToggleGrid", '0', 0, ID_GRID_TOGGLE, "menu_grid_toggle"}, + {"ToggleGrid", GDK_KP_0, 0, ID_GRID_TOGGLE, "menu_grid_toggle"}, {"SetGrid1", '1', 0, ID_GRID_1, "menu_grid_1"}, + {"SetGrid1", GDK_KP_1, 0, ID_GRID_1, "menu_grid_1"}, {"SetGrid2", '2', 0, ID_GRID_2, "menu_grid_2"}, + {"SetGrid2", GDK_KP_2, 0, ID_GRID_2, "menu_grid_2"}, {"SetGrid4", '3', 0, ID_GRID_4, "menu_grid_4"}, + {"SetGrid4", GDK_KP_3, 0, ID_GRID_4, "menu_grid_4"}, {"SetGrid8", '4', 0, ID_GRID_8, "menu_grid_8"}, + {"SetGrid8", GDK_KP_4, 0, ID_GRID_8, "menu_grid_8"}, {"SetGrid16", '5', 0, ID_GRID_16, "menu_grid_16"}, + {"SetGrid16", GDK_KP_5, 0, ID_GRID_16, "menu_grid_16"}, {"SetGrid32", '6', 0, ID_GRID_32, "menu_grid_32"}, + {"SetGrid32", GDK_KP_6, 0, ID_GRID_32, "menu_grid_32"}, {"SetGrid64", '7', 0, ID_GRID_64, "menu_grid_64"}, + {"SetGrid64", GDK_KP_7, 0, ID_GRID_64, "menu_grid_64"}, {"SetGrid128", '8', 0, ID_GRID_128, "menu_grid_128"}, + {"SetGrid128", GDK_KP_8, 0, ID_GRID_128, "menu_grid_128"}, {"SetGrid256", '9', 0, ID_GRID_256, "menu_grid_256"}, + {"SetGrid256", GDK_KP_9, 0, ID_GRID_256, "menu_grid_256"}, {"DragEdges", 'E', 0, ID_SELECTION_DRAGEDGES, "menu_selection_dragedges"}, {"DragVertices", 'V', 0, ID_SELECTION_DRAGVERTECIES, "menu_selection_dragvertecies"}, {"ViewEntityInfo", 'N', 0, ID_VIEW_ENTITY, "menu_view_entity"}, From 565a183cef9a05cf32da64dafc7cc15d065c608d Mon Sep 17 00:00:00 2001 From: Mateos81 Date: Mon, 5 Oct 2015 23:20:30 +0200 Subject: [PATCH 3/5] Step 2: Alt + Numeric Keypad filters --- radiant/mainframe.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/radiant/mainframe.cpp b/radiant/mainframe.cpp index 62c09a35..96a500b2 100644 --- a/radiant/mainframe.cpp +++ b/radiant/mainframe.cpp @@ -268,16 +268,26 @@ SCommandInfo g_Commands[] = {"Sleep", 'P', 0x05, ID_FILE_SLEEP, "menu_file_sleep"}, {"SimplePatchMesh", 'P', 0x01, ID_CURVE_SIMPLEPATCHMESH, "menu_simplepatchmesh"}, {"FilterWorldBrushes", '1', RAD_ALT, ID_FILTER_WORLD, "menu_filter_world"}, + {"FilterWorldBrushes", GDK_KP_1, RAD_ALT, ID_FILTER_WORLD, "menu_filter_world"}, {"FilterEntities", '2', RAD_ALT, ID_FILTER_ENTITIES, "menu_filter_entities"}, + {"FilterEntities", GDK_KP_2, RAD_ALT, ID_FILTER_ENTITIES, "menu_filter_entities"}, {"FilterAreaportals", '3', RAD_ALT, ID_FILTER_AREAPORTALS, "menu_filter_areaportals"}, + {"FilterAreaportals", GDK_KP_3, RAD_ALT, ID_FILTER_AREAPORTALS, "menu_filter_areaportals"}, {"FilterTranslucent", '4', RAD_ALT, ID_FILTER_TRANSLUCENT, "menu_filter_translucent"}, + {"FilterTranslucent", GDK_KP_4, RAD_ALT, ID_FILTER_TRANSLUCENT, "menu_filter_translucent"}, {"FilterLiquids", '5', RAD_ALT, ID_FILTER_LIQUIDS, "menu_filter_liquids"}, + {"FilterLiquids", GDK_KP_5, RAD_ALT, ID_FILTER_LIQUIDS, "menu_filter_liquids"}, {"FilterCaulk", '6', RAD_ALT, ID_FILTER_CAULK, "menu_filter_caulk"}, + {"FilterCaulk", GDK_KP_6, RAD_ALT, ID_FILTER_CAULK, "menu_filter_caulk"}, {"FilterClips", '7', RAD_ALT, ID_FILTER_CLIPS, "menu_filter_clips"}, + {"FilterClips", GDK_KP_7, RAD_ALT, ID_FILTER_CLIPS, "menu_filter_clips"}, {"FilterBotClips", 'M', RAD_ALT, ID_FILTER_BOTCLIPS, "menu_filter_botclips"}, {"FilterPaths", '8', RAD_ALT, ID_FILTER_PATHS, "menu_filter_paths"}, + {"FilterPaths", GDK_KP_8, RAD_ALT, ID_FILTER_PATHS, "menu_filter_paths"}, {"FilterClusterportals", '9', RAD_ALT, ID_FILTER_CLUSTERPORTALS, "menu_filter_clusterportals"}, + {"FilterClusterportals", GDK_KP_9, RAD_ALT, ID_FILTER_CLUSTERPORTALS, "menu_filter_clusterportals"}, {"FilterLights", '0', RAD_ALT, ID_FILTER_LIGHTS, "menu_filter_lights"}, + {"FilterLights", GDK_KP_0, RAD_ALT, ID_FILTER_LIGHTS, "menu_filter_lights"}, {"FilterPatches", 'P', RAD_CONTROL, ID_FILTER_PATCHES, "menu_filter_patches"}, {"FilterDetails", 'D', RAD_CONTROL, ID_FILTER_DETAILS, "menu_filter_details"}, {"FilterStructural", 'D', RAD_CONTROL | RAD_SHIFT, ID_FILTER_STRUCTURAL, "menu_filter_structural"}, From 98476ca2e646e5b1197b46d70fee5b5888b5b16f Mon Sep 17 00:00:00 2001 From: Mateos81 Date: Tue, 6 Oct 2015 18:09:05 +0200 Subject: [PATCH 4/5] Replaced spaces by tabs... Sorry ^^' --- radiant/mainframe.cpp | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/radiant/mainframe.cpp b/radiant/mainframe.cpp index 96a500b2..79b14500 100644 --- a/radiant/mainframe.cpp +++ b/radiant/mainframe.cpp @@ -162,25 +162,25 @@ SCommandInfo g_Commands[] = {"CameraStrafeRight", GDK_period, 0, ID_CAMERA_STRAFERIGHT, "menu_camera_straferight"}, {"CameraStrafeLeft", GDK_comma, 0, ID_CAMERA_STRAFELEFT, "menu_camera_strafeleft"}, {"ToggleGrid", '0', 0, ID_GRID_TOGGLE, "menu_grid_toggle"}, - {"ToggleGrid", GDK_KP_0, 0, ID_GRID_TOGGLE, "menu_grid_toggle"}, + {"ToggleGrid", GDK_KP_0, 0, ID_GRID_TOGGLE, "menu_grid_toggle"}, {"SetGrid1", '1', 0, ID_GRID_1, "menu_grid_1"}, - {"SetGrid1", GDK_KP_1, 0, ID_GRID_1, "menu_grid_1"}, + {"SetGrid1", GDK_KP_1, 0, ID_GRID_1, "menu_grid_1"}, {"SetGrid2", '2', 0, ID_GRID_2, "menu_grid_2"}, - {"SetGrid2", GDK_KP_2, 0, ID_GRID_2, "menu_grid_2"}, + {"SetGrid2", GDK_KP_2, 0, ID_GRID_2, "menu_grid_2"}, {"SetGrid4", '3', 0, ID_GRID_4, "menu_grid_4"}, - {"SetGrid4", GDK_KP_3, 0, ID_GRID_4, "menu_grid_4"}, + {"SetGrid4", GDK_KP_3, 0, ID_GRID_4, "menu_grid_4"}, {"SetGrid8", '4', 0, ID_GRID_8, "menu_grid_8"}, - {"SetGrid8", GDK_KP_4, 0, ID_GRID_8, "menu_grid_8"}, + {"SetGrid8", GDK_KP_4, 0, ID_GRID_8, "menu_grid_8"}, {"SetGrid16", '5', 0, ID_GRID_16, "menu_grid_16"}, - {"SetGrid16", GDK_KP_5, 0, ID_GRID_16, "menu_grid_16"}, + {"SetGrid16", GDK_KP_5, 0, ID_GRID_16, "menu_grid_16"}, {"SetGrid32", '6', 0, ID_GRID_32, "menu_grid_32"}, - {"SetGrid32", GDK_KP_6, 0, ID_GRID_32, "menu_grid_32"}, + {"SetGrid32", GDK_KP_6, 0, ID_GRID_32, "menu_grid_32"}, {"SetGrid64", '7', 0, ID_GRID_64, "menu_grid_64"}, - {"SetGrid64", GDK_KP_7, 0, ID_GRID_64, "menu_grid_64"}, + {"SetGrid64", GDK_KP_7, 0, ID_GRID_64, "menu_grid_64"}, {"SetGrid128", '8', 0, ID_GRID_128, "menu_grid_128"}, - {"SetGrid128", GDK_KP_8, 0, ID_GRID_128, "menu_grid_128"}, + {"SetGrid128", GDK_KP_8, 0, ID_GRID_128, "menu_grid_128"}, {"SetGrid256", '9', 0, ID_GRID_256, "menu_grid_256"}, - {"SetGrid256", GDK_KP_9, 0, ID_GRID_256, "menu_grid_256"}, + {"SetGrid256", GDK_KP_9, 0, ID_GRID_256, "menu_grid_256"}, {"DragEdges", 'E', 0, ID_SELECTION_DRAGEDGES, "menu_selection_dragedges"}, {"DragVertices", 'V', 0, ID_SELECTION_DRAGVERTECIES, "menu_selection_dragvertecies"}, {"ViewEntityInfo", 'N', 0, ID_VIEW_ENTITY, "menu_view_entity"}, @@ -268,26 +268,26 @@ SCommandInfo g_Commands[] = {"Sleep", 'P', 0x05, ID_FILE_SLEEP, "menu_file_sleep"}, {"SimplePatchMesh", 'P', 0x01, ID_CURVE_SIMPLEPATCHMESH, "menu_simplepatchmesh"}, {"FilterWorldBrushes", '1', RAD_ALT, ID_FILTER_WORLD, "menu_filter_world"}, - {"FilterWorldBrushes", GDK_KP_1, RAD_ALT, ID_FILTER_WORLD, "menu_filter_world"}, + {"FilterWorldBrushes", GDK_KP_1, RAD_ALT, ID_FILTER_WORLD, "menu_filter_world"}, {"FilterEntities", '2', RAD_ALT, ID_FILTER_ENTITIES, "menu_filter_entities"}, - {"FilterEntities", GDK_KP_2, RAD_ALT, ID_FILTER_ENTITIES, "menu_filter_entities"}, + {"FilterEntities", GDK_KP_2, RAD_ALT, ID_FILTER_ENTITIES, "menu_filter_entities"}, {"FilterAreaportals", '3', RAD_ALT, ID_FILTER_AREAPORTALS, "menu_filter_areaportals"}, - {"FilterAreaportals", GDK_KP_3, RAD_ALT, ID_FILTER_AREAPORTALS, "menu_filter_areaportals"}, + {"FilterAreaportals", GDK_KP_3, RAD_ALT, ID_FILTER_AREAPORTALS, "menu_filter_areaportals"}, {"FilterTranslucent", '4', RAD_ALT, ID_FILTER_TRANSLUCENT, "menu_filter_translucent"}, - {"FilterTranslucent", GDK_KP_4, RAD_ALT, ID_FILTER_TRANSLUCENT, "menu_filter_translucent"}, + {"FilterTranslucent", GDK_KP_4, RAD_ALT, ID_FILTER_TRANSLUCENT, "menu_filter_translucent"}, {"FilterLiquids", '5', RAD_ALT, ID_FILTER_LIQUIDS, "menu_filter_liquids"}, - {"FilterLiquids", GDK_KP_5, RAD_ALT, ID_FILTER_LIQUIDS, "menu_filter_liquids"}, + {"FilterLiquids", GDK_KP_5, RAD_ALT, ID_FILTER_LIQUIDS, "menu_filter_liquids"}, {"FilterCaulk", '6', RAD_ALT, ID_FILTER_CAULK, "menu_filter_caulk"}, - {"FilterCaulk", GDK_KP_6, RAD_ALT, ID_FILTER_CAULK, "menu_filter_caulk"}, + {"FilterCaulk", GDK_KP_6, RAD_ALT, ID_FILTER_CAULK, "menu_filter_caulk"}, {"FilterClips", '7', RAD_ALT, ID_FILTER_CLIPS, "menu_filter_clips"}, - {"FilterClips", GDK_KP_7, RAD_ALT, ID_FILTER_CLIPS, "menu_filter_clips"}, + {"FilterClips", GDK_KP_7, RAD_ALT, ID_FILTER_CLIPS, "menu_filter_clips"}, {"FilterBotClips", 'M', RAD_ALT, ID_FILTER_BOTCLIPS, "menu_filter_botclips"}, {"FilterPaths", '8', RAD_ALT, ID_FILTER_PATHS, "menu_filter_paths"}, - {"FilterPaths", GDK_KP_8, RAD_ALT, ID_FILTER_PATHS, "menu_filter_paths"}, + {"FilterPaths", GDK_KP_8, RAD_ALT, ID_FILTER_PATHS, "menu_filter_paths"}, {"FilterClusterportals", '9', RAD_ALT, ID_FILTER_CLUSTERPORTALS, "menu_filter_clusterportals"}, - {"FilterClusterportals", GDK_KP_9, RAD_ALT, ID_FILTER_CLUSTERPORTALS, "menu_filter_clusterportals"}, + {"FilterClusterportals", GDK_KP_9, RAD_ALT, ID_FILTER_CLUSTERPORTALS, "menu_filter_clusterportals"}, {"FilterLights", '0', RAD_ALT, ID_FILTER_LIGHTS, "menu_filter_lights"}, - {"FilterLights", GDK_KP_0, RAD_ALT, ID_FILTER_LIGHTS, "menu_filter_lights"}, + {"FilterLights", GDK_KP_0, RAD_ALT, ID_FILTER_LIGHTS, "menu_filter_lights"}, {"FilterPatches", 'P', RAD_CONTROL, ID_FILTER_PATCHES, "menu_filter_patches"}, {"FilterDetails", 'D', RAD_CONTROL, ID_FILTER_DETAILS, "menu_filter_details"}, {"FilterStructural", 'D', RAD_CONTROL | RAD_SHIFT, ID_FILTER_STRUCTURAL, "menu_filter_structural"}, From 86a0a8d8c20949b8c8a1bba6b7144a5a95b7f4a6 Mon Sep 17 00:00:00 2001 From: Pan7 Date: Wed, 7 Oct 2015 11:06:01 +0200 Subject: [PATCH 5/5] Fix shrinking console --- radiant/mainframe.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/radiant/mainframe.cpp b/radiant/mainframe.cpp index 55ca61be..4d6dd0e1 100644 --- a/radiant/mainframe.cpp +++ b/radiant/mainframe.cpp @@ -2495,6 +2495,7 @@ void MainFrame::Create(){ MRU_Load(); create_main_toolbar( window, vbox ); create_plugin_toolbar( window,vbox ); + create_main_statusbar( window, vbox ); m_nCurrentStyle = g_PrefsDlg.m_nView; @@ -2608,7 +2609,7 @@ void MainFrame::Create(){ } } - gtk_paned_set_position( GTK_PANED( m_pSplits[0] ), g_PrefsDlg.mWindowInfo.nXYHeight + 28 ); + gtk_paned_set_position( GTK_PANED( m_pSplits[0] ), g_PrefsDlg.mWindowInfo.nXYHeight ); if ( CurrentStyle() == eRegular ) { gtk_paned_set_position( GTK_PANED( m_pSplits[2] ), g_PrefsDlg.mWindowInfo.nZWidth ); @@ -2876,8 +2877,6 @@ void MainFrame::Create(){ g_pParentWnd->OnEntitiesSetViewAs( 0 ); - create_main_statusbar( window, vbox ); - LoadCommandMap(); ShowMenuItemKeyBindings( window );