2924{
2926
2927 BOOST_LOG_TRIVIAL(debug) << __FUNCTION__ << boost::format(", enter");
2930
2933
2934
2935
2936#if HAS_COL_HEADER
2937 m_object_grid->SetColLabelAlignment(wxALIGN_LEFT, wxALIGN_CENTER);
2938
2942
2961#else
2963#endif
2965
2970
2971
2972
2973 wxGridCellAttr *attr;
2974 attr = new wxGridCellAttr;
2975
2976 attr->SetBackgroundColour(*wxWHITE);
2977 attr->SetTextColour(*wxBLACK);
2978 attr->SetAlignment(wxALIGN_LEFT, wxALIGN_CENTRE);
2979 attr->SetReadOnly(true);
2981#if HAS_COL_HEADER
2983#endif
2984
2986
2995
2996
2997
3000
3004
3005 for (
int col = 0; col <
cols; col++)
3006 {
3009
3010 for (
int row = 1; row <
rows; row++)
3011 {
3013
3014 m_object_grid->SetCellAlignment(row, col, grid_col->horizontal_align, wxALIGN_CENTRE );
3016
3019
3020 if (grid_col->b_icon) {
3021 m_object_grid->SetCellRenderer(row, col,
new GridCellIconRenderer());
3023 }
3024
3025
3026
3027
3028
3029 else {
3030 if (!grid_col->b_editable)
3032
3033 switch (grid_col->type)
3034 {
3036 m_object_grid->SetCellEditor(row, col,
new GridCellTextEditor());
3037
3038 m_object_grid->SetCellFitMode(row, col, wxGridFitMode::Ellipsize());
3039 break;
3041 m_object_grid->SetCellEditor(row, col,
new GridCellSupportEditor());
3042
3043
3044 m_object_grid->SetCellRenderer(row, col,
new GridCellSupportRenderer());
3045 break;
3047 m_object_grid->SetCellEditor(row, col,
new GridCellTextEditor());
3048 m_object_grid->SetCellRenderer(row, col,
new wxGridCellNumberRenderer());
3049 break;
3056 GridCellFilamentsEditor* filament_editor =
new GridCellFilamentsEditor(grid_col->choices,
false, &
m_color_bitmaps);
3058 m_object_grid->SetCellRenderer(row, col,
new GridCellFilamentsRenderer());
3059 }
3060 else {
3061 m_object_grid->SetCellEditor(row, col,
new GridCellTextEditor());
3062 auto gcfil = new GridCellFilamentsRenderer();
3065
3066 }
3067 }
3068 else {
3069 GridCellChoiceEditor* combo_editor = new GridCellChoiceEditor(grid_col->choices);
3071 m_object_grid->SetCellRenderer(row, col,
new wxGridCellChoiceRenderer());
3072 }
3073 break;
3075 m_object_grid->SetCellEditor(row, col,
new GridCellTextEditor());
3077 m_object_grid->SetCellRenderer(row, col,
new wxGridCellFloatRenderer(6, 0));
3078 }
3079 else {
3080 m_object_grid->SetCellRenderer(row, col,
new wxGridCellFloatRenderer(6, 2));
3081 }
3082
3083 break;
3084 }
3086 {
3087 m_object_grid->SetCellEditor(row, col,
new GridCellTextEditor());
3088 m_object_grid->SetCellRenderer(row, col,
new wxGridCellFloatRenderer(6,1));
3089 break;
3090 }
3091 default:
3092 break;
3093 }
3096
3097
3098
3099
3100 }
3101 }
3102 }
3103 }
3104
3106 {
3108 if (grid_col->size > 0) {
3111 }
3112 }
3114
3116 switch (i) {
3117
3118
3119
3120
3121
3124 break;
3125
3128 break;
3129
3130
3131
3132
3133
3136 break;
3137
3140 if (width < m_object_grid->GetTextExtent(("000.00")).x) {
3142 }
3144 break;
3145 }
3146
3149 break;
3150
3153 if (width < m_object_grid->GetTextExtent(("000.00")).x) {
3155 }
3157 break;
3158 }
3161 break;
3162
3165 break;
3166
3169 break;
3170
3173 break;
3174
3177 break;
3178
3181 break;
3182
3185 break;
3188 if (width < m_object_grid->GetTextExtent((
"000.00")).x) {
width =
m_object_grid->GetTextExtent((
"000.00")).x; }
3190 break;
3191 }
3194 break;
3195 }
3196 }
3197
3198
3201}
#define _L(s)
Definition OBJ.cpp:34
static wxFont Body_13
Definition Label.hpp:54
static wxFont Head_13
Definition Label.hpp:46
@ col_wall_loops
Definition GUI_ObjectTable.hpp:324
@ col_fill_density
Definition GUI_ObjectTable.hpp:326
@ col_speed_perimeter_reset
Definition GUI_ObjectTable.hpp:333
@ col_printable
Definition GUI_ObjectTable.hpp:315
@ col_brim_type
Definition GUI_ObjectTable.hpp:330
@ col_enable_support_reset
Definition GUI_ObjectTable.hpp:329
@ col_filaments
Definition GUI_ObjectTable.hpp:320
@ col_layer_height
Definition GUI_ObjectTable.hpp:322
@ col_layer_height_reset
Definition GUI_ObjectTable.hpp:323
@ col_fill_density_reset
Definition GUI_ObjectTable.hpp:327
@ col_filaments_reset
Definition GUI_ObjectTable.hpp:321
@ col_printable_reset
Definition GUI_ObjectTable.hpp:316
@ col_plate_index
Definition GUI_ObjectTable.hpp:317
@ col_brim_type_reset
Definition GUI_ObjectTable.hpp:331
@ col_enable_support
Definition GUI_ObjectTable.hpp:328
@ col_max
Definition GUI_ObjectTable.hpp:334
@ col_wall_loops_reset
Definition GUI_ObjectTable.hpp:325
@ col_speed_perimeter
Definition GUI_ObjectTable.hpp:332
@ col_name
Definition GUI_ObjectTable.hpp:319
static wxColour darkModeColorFor(wxColour const &color)
Definition StateColor.cpp:219
@ SUPPORT_BLOCKER
Definition Model.hpp:360
@ NEGATIVE_VOLUME
Definition Model.hpp:358
@ SUPPORT_ENFORCER
Definition Model.hpp:361
@ coString
Definition Config.hpp:192
@ coEnum
Definition Config.hpp:214
@ coInt
Definition Config.hpp:188
@ coBool
Definition Config.hpp:210
@ coFloat
Definition Config.hpp:184
@ coPercent
Definition Config.hpp:196
bool is_precise_seam(ModelVolumeType t)
Definition Model.hpp:373
size_t cols(const T &raster)
Definition MarchingSquares.hpp:173
size_t rows(const T &raster)
Definition MarchingSquares.hpp:171