OXYGENHUB
◆ main openmsx / src / 3rdparty / ImGuiFileDialog / ImGuiFileDialogConfig.h
5.3 KiB · Objective-C · last changed chore(): initial commit 1 month ago source blame history raw
e8555c89 Andy McCall 1
#pragma once
2
3
#include <CustomFont.h>
4
5
// uncomment and modify defines under for customize ImGuiFileDialog
6
7
// uncomment if you need to use your FileSystem Interface
8
// if commented, you have two defualt interface, std::filesystem or dirent
9
// #define USE_CUSTOM_FILESYSTEM
10
11
// this options need c++17
12
#define USE_STD_FILESYSTEM
13
14
//#define MAX_FILE_DIALOG_NAME_BUFFER 1024
15
//#define MAX_PATH_BUFFER_SIZE 1024
16
17
// the slash's buttons in path can be used for quick select parallel directories
18
#define USE_QUICK_PATH_SELECT
19
20
// the spacing between button path's can be customized.
21
// if disabled the spacing is defined by the imgui theme
22
// define the space between path buttons
23
#define CUSTOM_PATH_SPACING 2
24
25
//#define USE_THUMBNAILS
26
//the thumbnail generation use the stb_image and stb_resize lib who need to define the implementation
27
//btw if you already use them in your app, you can have compiler error due to "implementation found in double"
28
//so uncomment these line for prevent the creation of implementation of these libs again
29
//#define DONT_DEFINE_AGAIN__STB_IMAGE_IMPLEMENTATION
30
//#define DONT_DEFINE_AGAIN__STB_IMAGE_RESIZE_IMPLEMENTATION
31
//#define IMGUI_RADIO_BUTTON RadioButton
32
//#define DisplayMode_ThumbailsList_ImageHeight 32.0f
33
//#define tableHeaderFileThumbnailsString "Thumbnails"
34
#define DisplayMode_FilesList_ButtonString ICON_IGFD_FILE_LIST
35
//#define DisplayMode_FilesList_ButtonHelp "File List"
36
#define DisplayMode_ThumbailsList_ButtonString ICON_IGFD_FILE_LIST_THUMBNAILS
37
//#define DisplayMode_ThumbailsList_ButtonHelp "Thumbnails List"
38
#define DisplayMode_ThumbailsGrid_ButtonString ICON_IGFD_FILE_GRID_THUMBNAILS
39
//#define DisplayMode_ThumbailsGrid_ButtonHelp "Thumbnails Grid"
40
41
#define USE_EXPLORATION_BY_KEYS
42
// this mapping by default is for GLFW but you can use another
43
//#include <GLFW/glfw3.h>
44
// Up key for explore to the top
45
#define IGFD_KEY_UP ImGuiKey_UpArrow
46
// Down key for explore to the bottom
47
#define IGFD_KEY_DOWN ImGuiKey_DownArrow
48
// Enter key for open directory
49
#define IGFD_KEY_ENTER ImGuiKey_Enter
50
// BackSpace for coming back to the last directory
51
#define IGFD_KEY_BACKSPACE ImGuiKey_Backspace
52
53
// by ex you can quit the dialog by pressing the key escape
54
#define USE_DIALOG_EXIT_WITH_KEY
55
#define IGFD_EXIT_KEY ImGuiKey_Escape
56
57
// widget
58
// begin combo widget
59
// #define IMGUI_BEGIN_COMBO ImGui::BeginCombo
60
// when auto resized, FILTER_COMBO_MIN_WIDTH will be considered has minimum width
61
// FILTER_COMBO_AUTO_SIZE is enabled by default now to 1
62
// uncomment if you want disable
63
//#define FILTER_COMBO_AUTO_SIZE 0
64
// filter combobox width
65
//#define FILTER_COMBO_MIN_WIDTH 120.0f
66
// button widget use for compose path
67
//#define IMGUI_PATH_BUTTON ImGui::Button
68
// standard button
69
//#define IMGUI_BUTTON ImGui::Button
70
71
// locales string
72
#define createDirButtonString ICON_IGFD_ADD
73
#define resetButtonString ICON_IGFD_UNDO
74
#define drivesButtonString ICON_IGFD_DRIVES
75
#define editPathButtonString ICON_IGFD_EDIT
76
#define searchString ICON_IGFD_FILTER
77
#define dirEntryString ICON_IGFD_FOLDER
78
#define linkEntryString ICON_IGFD_LINK
79
#define fileEntryString ICON_IGFD_FILE
80
//#define buttonResetSearchString "Reset filter"
81
//#define buttonDriveString "Drives"
82
//#define buttonEditPathString "Edit path\nYou can also right click on path buttons"
83
//#define buttonResetPathString "Reset to current directory"
84
//#define buttonCreateDirString "Create Directory"
85
//#define OverWriteDialogTitleString "The file Already Exist !"
86
//#define OverWriteDialogMessageString "Would you like to OverWrite it ?"
87
#define OverWriteDialogConfirmButtonString ICON_IGFD_OK " Confirm"
88
#define OverWriteDialogCancelButtonString ICON_IGFD_CANCEL " Cancel"
89
90
//Validation buttons
91
#define okButtonString ICON_IGFD_OK " OK"
92
#define okButtonWidth 100.0f
93
#define cancelButtonString ICON_IGFD_CANCEL " Cancel"
94
#define cancelButtonWidth 100.0f
95
//alignment [0:1], 0.0 is left, 0.5 middle, 1.0 right, and other ratios
96
#define okCancelButtonAlignement 0.0f
97
//#define invertOkAndCancelButtons 0
98
99
// DateTimeFormat
100
// see strftime function in <ctime> for customize
101
// "%Y/%m/%d %H:%M" give 2021:01:22 11:47
102
// "%Y/%m/%d %i:%M%p" give 2021:01:22 11:45PM
103
//#define DateTimeFormat "%Y/%m/%d %i:%M%p"
104
105
// theses icons will appear in table headers
106
#define USE_CUSTOM_SORTING_ICON
107
#define tableHeaderAscendingIcon ICON_IGFD_CHEVRON_UP
108
#define tableHeaderDescendingIcon ICON_IGFD_CHEVRON_DOWN
109
//#define tableHeaderFileNameString " File name"
110
//#define tableHeaderFileTypeString " Type"
111
//#define tableHeaderFileSizeString " Size"
112
//#define tableHeaderFileDateTimeString " Date"
113
#define fileSizeBytes "B"
114
#define fileSizeKiloBytes "kB"
115
#define fileSizeMegaBytes "MB"
116
#define fileSizeGigaBytes "GB"
117
118
// default table sort field (must be FIELD_FILENAME, FIELD_TYPE, FIELD_SIZE, FIELD_DATE or FIELD_THUMBNAILS)
119
//#define defaultSortField FIELD_FILENAME
120
121
// default table sort order for each field (true => Descending, false => Ascending)
122
//#define defaultSortOrderFilename true
123
//#define defaultSortOrderType true
124
//#define defaultSortOrderSize true
125
//#define defaultSortOrderDate true
126
//#define defaultSortOrderThumbnails true
127
128
#define USE_BOOKMARK
129
//#define bookmarkPaneWith 150.0f
130
//#define IMGUI_TOGGLE_BUTTON ToggleButton
131
#define bookmarksButtonString ICON_IGFD_BOOKMARK
132
//#define bookmarksButtonHelpString "Bookmark"
133
#define addBookmarkButtonString ICON_IGFD_ADD
134
#define removeBookmarkButtonString ICON_IGFD_REMOVE