The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

343 lines
12KB

  1. /*
  2. ==============================================================================
  3. This file is part of the JUCE 6 technical preview.
  4. Copyright (c) 2020 - Raw Material Software Limited
  5. You may use this code under the terms of the GPL v3
  6. (see www.gnu.org/licenses).
  7. For this technical preview, this file is not subject to commercial licensing.
  8. JUCE IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
  9. EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
  10. DISCLAIMED.
  11. ==============================================================================
  12. */
  13. /*******************************************************************************
  14. The block below describes the properties of this module, and is read by
  15. the Projucer to automatically generate project code that uses it.
  16. For details about the syntax and how to create or use a module, see the
  17. JUCE Module Format.txt file.
  18. BEGIN_JUCE_MODULE_DECLARATION
  19. ID: juce_gui_basics
  20. vendor: juce
  21. version: 6.0.0
  22. name: JUCE GUI core classes
  23. description: Basic user-interface components and related classes.
  24. website: http://www.juce.com/juce
  25. license: GPL/Commercial
  26. dependencies: juce_graphics juce_data_structures
  27. OSXFrameworks: Cocoa Carbon QuartzCore
  28. iOSFrameworks: UIKit MobileCoreServices
  29. END_JUCE_MODULE_DECLARATION
  30. *******************************************************************************/
  31. #pragma once
  32. #define JUCE_GUI_BASICS_H_INCLUDED
  33. #include <juce_graphics/juce_graphics.h>
  34. #include <juce_data_structures/juce_data_structures.h>
  35. //==============================================================================
  36. /** Config: JUCE_ENABLE_REPAINT_DEBUGGING
  37. If this option is turned on, each area of the screen that gets repainted will
  38. flash in a random colour, so that you can see exactly which bits of your
  39. components are being drawn.
  40. */
  41. #ifndef JUCE_ENABLE_REPAINT_DEBUGGING
  42. #define JUCE_ENABLE_REPAINT_DEBUGGING 0
  43. #endif
  44. /** Config: JUCE_USE_XRANDR
  45. Enables Xrandr multi-monitor support (Linux only).
  46. Unless you specifically want to disable this, it's best to leave this option turned on.
  47. Note that your users do not need to have Xrandr installed for your JUCE app to run, as
  48. the availability of Xrandr is queried during runtime.
  49. */
  50. #ifndef JUCE_USE_XRANDR
  51. #define JUCE_USE_XRANDR 1
  52. #endif
  53. /** Config: JUCE_USE_XINERAMA
  54. Enables Xinerama multi-monitor support (Linux only).
  55. Unless you specifically want to disable this, it's best to leave this option turned on.
  56. This will be used as a fallback if JUCE_USE_XRANDR not set or libxrandr cannot be found.
  57. Note that your users do not need to have Xinerama installed for your JUCE app to run, as
  58. the availability of Xinerama is queried during runtime.
  59. */
  60. #ifndef JUCE_USE_XINERAMA
  61. #define JUCE_USE_XINERAMA 1
  62. #endif
  63. /** Config: JUCE_USE_XSHM
  64. Enables X shared memory for faster rendering on Linux. This is best left turned on
  65. unless you have a good reason to disable it.
  66. */
  67. #ifndef JUCE_USE_XSHM
  68. #define JUCE_USE_XSHM 1
  69. #endif
  70. /** Config: JUCE_USE_XRENDER
  71. Enables XRender to allow semi-transparent windowing on Linux.
  72. */
  73. #ifndef JUCE_USE_XRENDER
  74. #define JUCE_USE_XRENDER 0
  75. #endif
  76. /** Config: JUCE_USE_XCURSOR
  77. Uses XCursor to allow ARGB cursor on Linux. This is best left turned on unless you have
  78. a good reason to disable it.
  79. */
  80. #ifndef JUCE_USE_XCURSOR
  81. #define JUCE_USE_XCURSOR 1
  82. #endif
  83. /** Config: JUCE_WIN_PER_MONITOR_DPI_AWARE
  84. Enables per-monitor DPI awareness on Windows 8.1 and above.
  85. */
  86. #ifndef JUCE_WIN_PER_MONITOR_DPI_AWARE
  87. #define JUCE_WIN_PER_MONITOR_DPI_AWARE 1
  88. #endif
  89. //==============================================================================
  90. namespace juce
  91. {
  92. class Component;
  93. class LookAndFeel;
  94. class MouseInputSource;
  95. class MouseInputSourceInternal;
  96. class ComponentPeer;
  97. class MouseEvent;
  98. struct MouseWheelDetails;
  99. struct PenDetails;
  100. class ToggleButton;
  101. class TextButton;
  102. class AlertWindow;
  103. class TextLayout;
  104. class ScrollBar;
  105. class ComboBox;
  106. class Button;
  107. class FilenameComponent;
  108. class ResizableWindow;
  109. class MenuBarComponent;
  110. class GlyphArrangement;
  111. class TableHeaderComponent;
  112. class Toolbar;
  113. class PopupMenu;
  114. class ProgressBar;
  115. class FileBrowserComponent;
  116. class DirectoryContentsDisplayComponent;
  117. class FilePreviewComponent;
  118. class CallOutBox;
  119. class Drawable;
  120. class DrawablePath;
  121. class DrawableComposite;
  122. class CaretComponent;
  123. class KeyPressMappingSet;
  124. class ApplicationCommandManagerListener;
  125. class DrawableButton;
  126. class Displays;
  127. class FlexBox;
  128. class Grid;
  129. }
  130. #include "mouse/juce_MouseCursor.h"
  131. #include "mouse/juce_MouseListener.h"
  132. #include "keyboard/juce_ModifierKeys.h"
  133. #include "mouse/juce_MouseInputSource.h"
  134. #include "mouse/juce_MouseEvent.h"
  135. #include "keyboard/juce_KeyPress.h"
  136. #include "keyboard/juce_KeyListener.h"
  137. #include "keyboard/juce_KeyboardFocusTraverser.h"
  138. #include "components/juce_ModalComponentManager.h"
  139. #include "components/juce_ComponentListener.h"
  140. #include "components/juce_CachedComponentImage.h"
  141. #include "components/juce_Component.h"
  142. #include "layout/juce_ComponentAnimator.h"
  143. #include "desktop/juce_Desktop.h"
  144. #include "desktop/juce_Displays.h"
  145. #include "layout/juce_ComponentBoundsConstrainer.h"
  146. #include "mouse/juce_ComponentDragger.h"
  147. #include "mouse/juce_DragAndDropTarget.h"
  148. #include "mouse/juce_DragAndDropContainer.h"
  149. #include "mouse/juce_FileDragAndDropTarget.h"
  150. #include "mouse/juce_SelectedItemSet.h"
  151. #include "mouse/juce_MouseInactivityDetector.h"
  152. #include "mouse/juce_TextDragAndDropTarget.h"
  153. #include "mouse/juce_TooltipClient.h"
  154. #include "keyboard/juce_CaretComponent.h"
  155. #include "keyboard/juce_SystemClipboard.h"
  156. #include "keyboard/juce_TextEditorKeyMapper.h"
  157. #include "keyboard/juce_TextInputTarget.h"
  158. #include "commands/juce_ApplicationCommandID.h"
  159. #include "commands/juce_ApplicationCommandInfo.h"
  160. #include "commands/juce_ApplicationCommandTarget.h"
  161. #include "commands/juce_ApplicationCommandManager.h"
  162. #include "commands/juce_KeyPressMappingSet.h"
  163. #include "buttons/juce_Button.h"
  164. #include "buttons/juce_ArrowButton.h"
  165. #include "buttons/juce_DrawableButton.h"
  166. #include "buttons/juce_HyperlinkButton.h"
  167. #include "buttons/juce_ImageButton.h"
  168. #include "buttons/juce_ShapeButton.h"
  169. #include "buttons/juce_TextButton.h"
  170. #include "buttons/juce_ToggleButton.h"
  171. #include "layout/juce_AnimatedPosition.h"
  172. #include "layout/juce_AnimatedPositionBehaviours.h"
  173. #include "layout/juce_ComponentBuilder.h"
  174. #include "layout/juce_ComponentMovementWatcher.h"
  175. #include "layout/juce_ConcertinaPanel.h"
  176. #include "layout/juce_GroupComponent.h"
  177. #include "layout/juce_ResizableBorderComponent.h"
  178. #include "layout/juce_ResizableCornerComponent.h"
  179. #include "layout/juce_ResizableEdgeComponent.h"
  180. #include "layout/juce_ScrollBar.h"
  181. #include "layout/juce_StretchableLayoutManager.h"
  182. #include "layout/juce_StretchableLayoutResizerBar.h"
  183. #include "layout/juce_StretchableObjectResizer.h"
  184. #include "layout/juce_TabbedButtonBar.h"
  185. #include "layout/juce_TabbedComponent.h"
  186. #include "layout/juce_Viewport.h"
  187. #include "menus/juce_PopupMenu.h"
  188. #include "menus/juce_MenuBarModel.h"
  189. #include "menus/juce_MenuBarComponent.h"
  190. #include "positioning/juce_RelativeCoordinate.h"
  191. #include "positioning/juce_MarkerList.h"
  192. #include "positioning/juce_RelativePoint.h"
  193. #include "positioning/juce_RelativeRectangle.h"
  194. #include "positioning/juce_RelativeCoordinatePositioner.h"
  195. #include "positioning/juce_RelativeParallelogram.h"
  196. #include "positioning/juce_RelativePointPath.h"
  197. #include "drawables/juce_Drawable.h"
  198. #include "drawables/juce_DrawableShape.h"
  199. #include "drawables/juce_DrawableComposite.h"
  200. #include "drawables/juce_DrawableImage.h"
  201. #include "drawables/juce_DrawablePath.h"
  202. #include "drawables/juce_DrawableRectangle.h"
  203. #include "drawables/juce_DrawableText.h"
  204. #include "widgets/juce_TextEditor.h"
  205. #include "widgets/juce_Label.h"
  206. #include "widgets/juce_ComboBox.h"
  207. #include "widgets/juce_ImageComponent.h"
  208. #include "widgets/juce_ListBox.h"
  209. #include "widgets/juce_ProgressBar.h"
  210. #include "widgets/juce_Slider.h"
  211. #include "widgets/juce_TableHeaderComponent.h"
  212. #include "widgets/juce_TableListBox.h"
  213. #include "widgets/juce_Toolbar.h"
  214. #include "widgets/juce_ToolbarItemComponent.h"
  215. #include "widgets/juce_ToolbarItemFactory.h"
  216. #include "widgets/juce_ToolbarItemPalette.h"
  217. #include "menus/juce_BurgerMenuComponent.h"
  218. #include "buttons/juce_ToolbarButton.h"
  219. #include "misc/juce_DropShadower.h"
  220. #include "misc/juce_JUCESplashScreen.h"
  221. #include "widgets/juce_TreeView.h"
  222. #include "windows/juce_TopLevelWindow.h"
  223. #include "windows/juce_AlertWindow.h"
  224. #include "windows/juce_CallOutBox.h"
  225. #include "windows/juce_ComponentPeer.h"
  226. #include "windows/juce_ResizableWindow.h"
  227. #include "windows/juce_DocumentWindow.h"
  228. #include "windows/juce_DialogWindow.h"
  229. #include "windows/juce_NativeMessageBox.h"
  230. #include "windows/juce_ThreadWithProgressWindow.h"
  231. #include "windows/juce_TooltipWindow.h"
  232. #include "layout/juce_MultiDocumentPanel.h"
  233. #include "layout/juce_SidePanel.h"
  234. #include "filebrowser/juce_FileBrowserListener.h"
  235. #include "filebrowser/juce_DirectoryContentsList.h"
  236. #include "filebrowser/juce_DirectoryContentsDisplayComponent.h"
  237. #include "filebrowser/juce_FileBrowserComponent.h"
  238. #include "filebrowser/juce_FileChooser.h"
  239. #include "filebrowser/juce_FileChooserDialogBox.h"
  240. #include "filebrowser/juce_FileListComponent.h"
  241. #include "filebrowser/juce_FilenameComponent.h"
  242. #include "filebrowser/juce_FilePreviewComponent.h"
  243. #include "filebrowser/juce_FileSearchPathListComponent.h"
  244. #include "filebrowser/juce_FileTreeComponent.h"
  245. #include "filebrowser/juce_ImagePreviewComponent.h"
  246. #include "filebrowser/juce_ContentSharer.h"
  247. #include "properties/juce_PropertyComponent.h"
  248. #include "properties/juce_BooleanPropertyComponent.h"
  249. #include "properties/juce_ButtonPropertyComponent.h"
  250. #include "properties/juce_ChoicePropertyComponent.h"
  251. #include "properties/juce_PropertyPanel.h"
  252. #include "properties/juce_SliderPropertyComponent.h"
  253. #include "properties/juce_TextPropertyComponent.h"
  254. #include "properties/juce_MultiChoicePropertyComponent.h"
  255. #include "application/juce_Application.h"
  256. #include "misc/juce_BubbleComponent.h"
  257. #include "lookandfeel/juce_LookAndFeel.h"
  258. #include "lookandfeel/juce_LookAndFeel_V2.h"
  259. #include "lookandfeel/juce_LookAndFeel_V1.h"
  260. #include "lookandfeel/juce_LookAndFeel_V3.h"
  261. #include "lookandfeel/juce_LookAndFeel_V4.h"
  262. #include "mouse/juce_LassoComponent.h"
  263. #if JUCE_LINUX
  264. #if JUCE_GUI_BASICS_INCLUDE_XHEADERS
  265. // If you're missing these headers, you need to install the libx11-dev package
  266. #include <X11/Xlib.h>
  267. #include <X11/Xatom.h>
  268. #include <X11/Xresource.h>
  269. #include <X11/Xutil.h>
  270. #include <X11/Xmd.h>
  271. #include <X11/keysym.h>
  272. #include <X11/XKBlib.h>
  273. #include <X11/cursorfont.h>
  274. #include <unistd.h>
  275. #if JUCE_USE_XRANDR
  276. // If you're missing this header, you need to install the libxrandr-dev package
  277. #include <X11/extensions/Xrandr.h>
  278. #endif
  279. #if JUCE_USE_XINERAMA
  280. // If you're missing this header, you need to install the libxinerama-dev package
  281. #include <X11/extensions/Xinerama.h>
  282. #endif
  283. #if JUCE_USE_XSHM
  284. #include <X11/extensions/XShm.h>
  285. #include <sys/shm.h>
  286. #include <sys/ipc.h>
  287. #endif
  288. #if JUCE_USE_XRENDER
  289. // If you're missing these headers, you need to install the libxrender-dev and libxcomposite-dev packages
  290. #include <X11/extensions/Xrender.h>
  291. #include <X11/extensions/Xcomposite.h>
  292. #endif
  293. #if JUCE_USE_XCURSOR
  294. // If you're missing this header, you need to install the libxcursor-dev package
  295. #include <X11/Xcursor/Xcursor.h>
  296. #endif
  297. #undef SIZEOF
  298. #undef KeyPress
  299. #include "native/x11/juce_linux_XWindowSystem.h"
  300. #include "native/x11/juce_linux_X11_Symbols.h"
  301. #endif
  302. #endif
  303. #include "layout/juce_FlexItem.h"
  304. #include "layout/juce_FlexBox.h"
  305. #include "layout/juce_GridItem.h"
  306. #include "layout/juce_Grid.h"