0.2.0
Loading...
Searching...
No Matches
InputWithUnit.hpp
Go to the documentation of this file.
1// This file is part of INSTINCT, the INS Toolkit for Integrated
2// Navigation Concepts and Training by the Institute of Navigation of
3// the University of Stuttgart, Germany.
4//
5// This Source Code Form is subject to the terms of the Mozilla Public
6// License, v. 2.0. If a copy of the MPL was not distributed with this
7// file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
13
14#pragma once
15
16#include <imgui.h>
17
18namespace NAV::gui::widgets
19{
27
41InputWithUnitChange InputFloatWithUnit(const char* label, float itemWidth, float unitWidth,
42 float* v, int* combo_current_item, const char* combo_items_separated_by_zeros,
43 float step = 0.0, float step_fast = 0.0, const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
44 int combo_popup_max_height_in_items = -1);
45
57InputWithUnitChange InputFloat2WithUnit(const char* label, float itemWidth, float unitWidth,
58 float v[2], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
59 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
60 int combo_popup_max_height_in_items = -1);
61
73InputWithUnitChange InputFloat3WithUnit(const char* label, float itemWidth, float unitWidth,
74 float v[3], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
75 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
76 int combo_popup_max_height_in_items = -1);
77
89InputWithUnitChange InputFloat4WithUnit(const char* label, float itemWidth, float unitWidth,
90 float v[4], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
91 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
92 int combo_popup_max_height_in_items = -1);
93
107InputWithUnitChange InputDoubleWithUnit(const char* label, float itemWidth, float unitWidth,
108 double* v, int* combo_current_item, const char* combo_items_separated_by_zeros,
109 double step = 0.0, double step_fast = 0.0, const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
110 int combo_popup_max_height_in_items = -1);
111
123InputWithUnitChange InputDouble2WithUnit(const char* label, float itemWidth, float unitWidth,
124 double v[2], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
125 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
126 int combo_popup_max_height_in_items = -1);
127
139InputWithUnitChange InputDouble3WithUnit(const char* label, float itemWidth, float unitWidth,
140 double v[3], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
141 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
142 int combo_popup_max_height_in_items = -1);
143
155InputWithUnitChange InputDouble4WithUnit(const char* label, float itemWidth, float unitWidth,
156 double v[4], int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
157 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
158 int combo_popup_max_height_in_items = -1);
159
160// ###########################################################################################################
161
177InputWithUnitChange InputFloatLWithUnit(const char* label, float itemWidth, float unitWidth,
178 float* v, float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros,
179 float step = 0.0, float step_fast = 0.0, const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
180 int combo_popup_max_height_in_items = -1);
181
195InputWithUnitChange InputFloat2LWithUnit(const char* label, float itemWidth, float unitWidth,
196 float v[2], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
197 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
198 int combo_popup_max_height_in_items = -1);
199
213InputWithUnitChange InputFloat3LWithUnit(const char* label, float itemWidth, float unitWidth,
214 float v[3], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
215 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
216 int combo_popup_max_height_in_items = -1);
217
231InputWithUnitChange InputFloat4LWithUnit(const char* label, float itemWidth, float unitWidth,
232 float v[4], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
233 const char* format = "%.3f", ImGuiInputTextFlags flags = 0,
234 int combo_popup_max_height_in_items = -1);
235
251InputWithUnitChange InputDoubleLWithUnit(const char* label, float itemWidth, float unitWidth,
252 double* v, double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros,
253 double step = 0.0, double step_fast = 0.0, const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
254 int combo_popup_max_height_in_items = -1);
255
269InputWithUnitChange InputDouble2LWithUnit(const char* label, float itemWidth, float unitWidth,
270 double v[2], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
271 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
272 int combo_popup_max_height_in_items = -1);
273
287InputWithUnitChange InputDouble3LWithUnit(const char* label, float itemWidth, float unitWidth,
288 double v[3], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
289 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
290 int combo_popup_max_height_in_items = -1);
291
305InputWithUnitChange InputDouble4LWithUnit(const char* label, float itemWidth, float unitWidth,
306 double v[4], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
307 const char* format = "%.6f", ImGuiInputTextFlags flags = 0,
308 int combo_popup_max_height_in_items = -1);
309
310// ###########################################################################################################
311
325InputWithUnitChange SliderFloatWithUnit(const char* label, float itemWidth, float unitWidth,
326 float* v, float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros,
327 const char* format = "%.3f", ImGuiSliderFlags flags = 0,
328 int combo_popup_max_height_in_items = -1);
329
343InputWithUnitChange SliderFloat2WithUnit(const char* label, float itemWidth, float unitWidth,
344 float v[2], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
345 const char* format = "%.3f", ImGuiSliderFlags flags = 0,
346 int combo_popup_max_height_in_items = -1);
347
361InputWithUnitChange SliderFloat3WithUnit(const char* label, float itemWidth, float unitWidth,
362 float v[3], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
363 const char* format = "%.3f", ImGuiSliderFlags flags = 0,
364 int combo_popup_max_height_in_items = -1);
365
379InputWithUnitChange SliderFloat4WithUnit(const char* label, float itemWidth, float unitWidth,
380 float v[4], float v_min, float v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
381 const char* format = "%.3f", ImGuiSliderFlags flags = 0,
382 int combo_popup_max_height_in_items = -1);
383
397InputWithUnitChange SliderDoubleWithUnit(const char* label, float itemWidth, float unitWidth,
398 double* v, double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros,
399 const char* format = "%.6f", ImGuiSliderFlags flags = 0,
400 int combo_popup_max_height_in_items = -1);
401
415InputWithUnitChange SliderDouble2WithUnit(const char* label, float itemWidth, float unitWidth,
416 double v[2], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
417 const char* format = "%.6f", ImGuiSliderFlags flags = 0,
418 int combo_popup_max_height_in_items = -1);
419
433InputWithUnitChange SliderDouble3WithUnit(const char* label, float itemWidth, float unitWidth,
434 double v[3], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
435 const char* format = "%.6f", ImGuiSliderFlags flags = 0,
436 int combo_popup_max_height_in_items = -1);
437
451InputWithUnitChange SliderDouble4WithUnit(const char* label, float itemWidth, float unitWidth,
452 double v[4], double v_min, double v_max, int* combo_current_item, const char* combo_items_separated_by_zeros, // NOLINT(hicpp-avoid-c-arrays,modernize-avoid-c-arrays,cppcoreguidelines-avoid-c-arrays)
453 const char* format = "%.6f", ImGuiSliderFlags flags = 0,
454 int combo_popup_max_height_in_items = -1);
455
456} // namespace NAV::gui::widgets
InputWithUnitChange InputFloatLWithUnit(const char *label, float itemWidth, float unitWidth, float *v, float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, float step=0.0, float step_fast=0.0, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloat4WithUnit(const char *label, float itemWidth, float unitWidth, float v[4], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble4LWithUnit(const char *label, float itemWidth, float unitWidth, double v[4], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble3LWithUnit(const char *label, float itemWidth, float unitWidth, double v[3], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDoubleWithUnit(const char *label, float itemWidth, float unitWidth, double *v, int *combo_current_item, const char *combo_items_separated_by_zeros, double step=0.0, double step_fast=0.0, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDoubleLWithUnit(const char *label, float itemWidth, float unitWidth, double *v, double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, double step=0.0, double step_fast=0.0, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble2WithUnit(const char *label, float itemWidth, float unitWidth, double v[2], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloat3LWithUnit(const char *label, float itemWidth, float unitWidth, float v[3], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloatWithUnit(const char *label, float itemWidth, float unitWidth, float *v, int *combo_current_item, const char *combo_items_separated_by_zeros, float step=0.0, float step_fast=0.0, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderDoubleWithUnit(const char *label, float itemWidth, float unitWidth, double *v, double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble2LWithUnit(const char *label, float itemWidth, float unitWidth, double v[2], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble4WithUnit(const char *label, float itemWidth, float unitWidth, double v[4], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderDouble4WithUnit(const char *label, float itemWidth, float unitWidth, double v[4], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderDouble2WithUnit(const char *label, float itemWidth, float unitWidth, double v[2], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderFloat4WithUnit(const char *label, float itemWidth, float unitWidth, float v[4], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderFloatWithUnit(const char *label, float itemWidth, float unitWidth, float *v, float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputDouble3WithUnit(const char *label, float itemWidth, float unitWidth, double v[3], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange
Return value signaling that the input or the unit changed.
Definition InputWithUnit.hpp:22
@ InputWithUnitChange_None
Nothing changed.
Definition InputWithUnit.hpp:23
@ InputWithUnitChange_Unit
The Unit changed.
Definition InputWithUnit.hpp:25
@ InputWithUnitChange_Input
The Input changed.
Definition InputWithUnit.hpp:24
InputWithUnitChange InputFloat3WithUnit(const char *label, float itemWidth, float unitWidth, float v[3], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderFloat2WithUnit(const char *label, float itemWidth, float unitWidth, float v[2], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderDouble3WithUnit(const char *label, float itemWidth, float unitWidth, double v[3], double v_min, double v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.6f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloat2LWithUnit(const char *label, float itemWidth, float unitWidth, float v[2], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloat2WithUnit(const char *label, float itemWidth, float unitWidth, float v[2], int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.
InputWithUnitChange SliderFloat3WithUnit(const char *label, float itemWidth, float unitWidth, float v[3], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiSliderFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an Slider GUI element to modify the provided value and also set its unit.
InputWithUnitChange InputFloat4LWithUnit(const char *label, float itemWidth, float unitWidth, float v[4], float v_min, float v_max, int *combo_current_item, const char *combo_items_separated_by_zeros, const char *format="%.3f", ImGuiInputTextFlags flags=0, int combo_popup_max_height_in_items=-1)
Shows an InputText GUI element to modify the provided value and also set its unit.