expo-juce 0.3.0 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +34 -0
- package/build/index.d.ts +21 -24
- package/build/index.d.ts.map +1 -1
- package/build/index.js +44 -48
- package/build/index.js.map +1 -1
- package/ios/BeeperAudioEngine.h +45 -0
- package/ios/BeeperAudioEngine.mm +352 -0
- package/ios/ExpoJuce.podspec +31 -8
- package/ios/ExpoJuceBridge.h +12 -12
- package/ios/ExpoJuceBridge.m +35 -100
- package/ios/ExpoJuceModule.swift +63 -85
- package/ios/JuceConfig.h +49 -14
- package/ios/JuceModule_audio_basics.mm +2 -0
- package/ios/JuceModule_audio_devices.mm +2 -0
- package/ios/JuceModule_audio_formats.mm +2 -0
- package/ios/JuceModule_audio_processors.mm +2 -0
- package/ios/JuceModule_core.mm +5 -0
- package/ios/JuceModule_data_structures.mm +2 -0
- package/ios/JuceModule_dsp.mm +2 -0
- package/ios/JuceModule_events.mm +2 -0
- package/ios/JuceModule_graphics.mm +2 -0
- package/ios/JuceModule_gui_basics.mm +2 -0
- package/ios/JuceModule_gui_extra.mm +2 -0
- package/ios/JuceModule_harfbuzz.mm +4 -0
- package/ios/PolySynthProcessor.h +83 -0
- package/ios/PolySynthProcessor.mm +164 -0
- package/ios/TransportEngine.h +35 -0
- package/ios/TransportEngine.mm +50 -0
- package/ios/Voice.h +59 -0
- package/ios/Voice.mm +157 -0
- package/ios/VoiceAllocator.h +22 -0
- package/ios/VoiceAllocator.mm +88 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioDeviceManager.cpp +1957 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioDeviceManager.h +586 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioIODevice.cpp +65 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioIODevice.h +368 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioIODeviceType.cpp +152 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_AudioIODeviceType.h +200 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_SampleRateHelpers.cpp +57 -0
- package/ios/juce_modules/juce_audio_devices/audio_io/juce_SystemAudioVolume.h +71 -0
- package/ios/juce_modules/juce_audio_devices/juce_audio_devices.cpp +277 -0
- package/ios/juce_modules/juce_audio_devices/juce_audio_devices.h +201 -0
- package/ios/juce_modules/juce_audio_devices/juce_audio_devices.mm +35 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/juce_MidiDevices.cpp +246 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/juce_MidiDevices.h +482 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/juce_MidiMessageCollector.cpp +170 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/juce_MidiMessageCollector.h +125 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/ump/juce_UMPBytestreamInputHandler.h +153 -0
- package/ios/juce_modules/juce_audio_devices/midi_io/ump/juce_UMPU32InputHandler.h +165 -0
- package/ios/juce_modules/juce_audio_devices/native/java/app/com/rmsl/juce/JuceMidiSupport.java +1121 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_ALSA_linux.cpp +1313 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_ASIO_windows.cpp +1654 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Audio_android.cpp +482 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Audio_ios.cpp +1508 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Audio_ios.h +106 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Bela_linux.cpp +612 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_CoreAudio_mac.cpp +2315 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_CoreMidi_mac.mm +1280 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_DirectSound_windows.cpp +1304 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_HighPerformanceAudioHelpers_android.h +137 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_JackAudio_linux.cpp +681 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Midi_android.cpp +1183 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Midi_linux.cpp +788 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Midi_windows.cpp +2038 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_Oboe_android.cpp +1440 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_OpenSL_android.cpp +1306 -0
- package/ios/juce_modules/juce_audio_devices/native/juce_WASAPI_windows.cpp +2032 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/.clang-tidy +3 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/AudioStream.h +706 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/AudioStreamBase.h +343 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/AudioStreamBuilder.h +670 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/AudioStreamCallback.h +193 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/Definitions.h +897 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/FifoBuffer.h +164 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/FifoControllerBase.h +112 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/FullDuplexStream.h +324 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/LatencyTuner.h +150 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/Oboe.h +40 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/OboeExtensions.h +64 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/ResultWithValue.h +155 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/StabilizedCallback.h +75 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/Utilities.h +99 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/include/oboe/Version.h +92 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/aaudio/AAudioExtensions.h +180 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/aaudio/AAudioLoader.cpp +506 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/aaudio/AAudioLoader.h +299 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/aaudio/AudioStreamAAudio.cpp +868 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/aaudio/AudioStreamAAudio.h +152 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AdpfWrapper.cpp +124 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AdpfWrapper.h +85 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AudioClock.h +75 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AudioSourceCaller.cpp +38 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AudioSourceCaller.h +83 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AudioStream.cpp +222 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/AudioStreamBuilder.cpp +224 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/DataConversionFlowGraph.cpp +266 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/DataConversionFlowGraph.h +86 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FilterAudioStream.cpp +106 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FilterAudioStream.h +227 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockAdapter.cpp +38 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockAdapter.h +67 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockReader.cpp +73 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockReader.h +60 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockWriter.cpp +73 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/FixedBlockWriter.h +54 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/LatencyTuner.cpp +108 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/MonotonicCounter.h +112 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/OboeDebug.h +41 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/OboeExtensions.cpp +36 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/QuirksManager.cpp +311 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/QuirksManager.h +134 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceFloatCaller.cpp +30 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceFloatCaller.h +44 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI16Caller.cpp +47 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI16Caller.h +49 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI24Caller.cpp +56 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI24Caller.h +53 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI32Caller.cpp +47 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/SourceI32Caller.h +53 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/StabilizedCallback.cpp +112 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/Trace.cpp +75 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/Trace.h +31 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/Utilities.cpp +333 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/common/Version.cpp +28 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoBuffer.cpp +178 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoController.cpp +30 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoController.h +62 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoControllerBase.cpp +68 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoControllerIndirect.cpp +32 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/fifo/FifoControllerIndirect.h +66 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ChannelCountConverter.cpp +52 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ChannelCountConverter.h +52 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ClipToRange.cpp +38 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ClipToRange.h +68 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/FlowGraphNode.cpp +114 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/FlowGraphNode.h +450 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/FlowgraphUtilities.h +55 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/Limiter.cpp +67 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/Limiter.h +64 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ManyToMultiConverter.cpp +47 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/ManyToMultiConverter.h +53 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MonoBlend.cpp +46 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MonoBlend.h +48 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MonoToMultiConverter.cpp +41 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MonoToMultiConverter.h +49 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MultiToManyConverter.cpp +47 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MultiToManyConverter.h +49 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MultiToMonoConverter.cpp +41 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/MultiToMonoConverter.h +49 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/RampLinear.cpp +81 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/RampLinear.h +96 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SampleRateConverter.cpp +71 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SampleRateConverter.h +63 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkFloat.cpp +46 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkFloat.h +45 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI16.cpp +57 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI16.h +43 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI24.cpp +66 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI24.h +44 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI32.cpp +55 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SinkI32.h +40 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceFloat.cpp +42 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceFloat.h +44 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI16.cpp +54 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI16.h +42 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI24.cpp +65 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI24.h +43 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI32.cpp +54 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/SourceI32.h +42 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/HyperbolicCosineWindow.h +71 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/IntegerRatio.cpp +50 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/IntegerRatio.h +54 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/KaiserWindow.h +90 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/LinearResampler.cpp +42 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/LinearResampler.h +47 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/MultiChannelResampler.cpp +171 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/MultiChannelResampler.h +281 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResampler.cpp +61 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResampler.h +53 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResamplerMono.cpp +63 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResamplerMono.h +41 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResamplerStereo.cpp +79 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/PolyphaseResamplerStereo.h +41 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/ResamplerDefinitions.h +27 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/SincResampler.cpp +72 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/SincResampler.h +50 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/SincResamplerStereo.cpp +81 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/flowgraph/resampler/SincResamplerStereo.h +42 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioInputStreamOpenSLES.cpp +360 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioInputStreamOpenSLES.h +66 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioOutputStreamOpenSLES.cpp +462 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioOutputStreamOpenSLES.h +80 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioStreamBuffered.cpp +285 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioStreamBuffered.h +96 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioStreamOpenSLES.cpp +499 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/AudioStreamOpenSLES.h +148 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/EngineOpenSLES.cpp +141 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/EngineOpenSLES.h +65 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/OpenSLESUtilities.cpp +96 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/OpenSLESUtilities.h +44 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/OutputMixerOpenSLES.cpp +74 -0
- package/ios/juce_modules/juce_audio_devices/native/oboe/src/opensles/OutputMixerOpenSLES.h +58 -0
- package/ios/juce_modules/juce_audio_devices/sources/juce_AudioSourcePlayer.cpp +193 -0
- package/ios/juce_modules/juce_audio_devices/sources/juce_AudioSourcePlayer.h +127 -0
- package/ios/juce_modules/juce_audio_devices/sources/juce_AudioTransportSource.cpp +295 -0
- package/ios/juce_modules/juce_audio_devices/sources/juce_AudioTransportSource.h +192 -0
- package/ios/juce_modules/juce_audio_processors/format/juce_AudioPluginFormat.cpp +107 -0
- package/ios/juce_modules/juce_audio_processors/format/juce_AudioPluginFormat.h +183 -0
- package/ios/juce_modules/juce_audio_processors/format/juce_AudioPluginFormatManager.cpp +212 -0
- package/ios/juce_modules/juce_audio_processors/format/juce_AudioPluginFormatManager.h +151 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/generate_lv2_bundle_sources.py +175 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/juce_lv2_config.h +87 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/COPYING +13 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/lilv/lilv.h +2117 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/lilv/lilvmm.hpp +440 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/collections.c +240 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/filesystem.c +564 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/filesystem.h +182 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/instance.c +115 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/lib.c +127 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/lilv_internal.h +477 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/node.c +413 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/plugin.c +1140 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/pluginclass.c +91 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/port.c +272 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/query.c +144 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/scalepoint.c +53 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/state.c +1541 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/ui.c +115 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/util.c +291 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/world.c +1249 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/zix/common.h +138 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/zix/tree.c +727 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv/src/zix/tree.h +164 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lilv_config.h +42 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/COPYING +16 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/atom-test-utils.c +73 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/atom-test.c +367 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/atom.h +260 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/atom.meta.ttl +542 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/atom.ttl +247 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/forge-overflow-test.c +235 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/forge.h +683 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/atom/util.h +523 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/buf-size/buf-size.h +51 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/buf-size/buf-size.meta.ttl +157 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/buf-size/buf-size.ttl +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/buf-size/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/attributes.h +59 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/lv2.h +484 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/lv2_util.h +103 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/lv2core.meta.ttl +905 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/lv2core.ttl +674 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/manifest.ttl +15 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/meta.ttl +199 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/core/people.ttl +51 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/data-access/data-access.h +73 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/data-access/data-access.meta.ttl +77 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/data-access/data-access.ttl +11 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/data-access/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/dynmanifest/dynmanifest.h +160 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/dynmanifest/dynmanifest.meta.ttl +131 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/dynmanifest/dynmanifest.ttl +25 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/dynmanifest/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/event/event-helpers.h +255 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/event/event.h +306 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/event/event.meta.ttl +246 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/event/event.ttl +86 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/event/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/instance-access/instance-access.h +41 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/instance-access/instance-access.meta.ttl +75 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/instance-access/instance-access.ttl +11 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/instance-access/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/log/log.h +113 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/log/log.meta.ttl +126 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/log/log.ttl +48 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/log/logger.h +157 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/log/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/midi/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/midi/midi.h +248 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/midi/midi.meta.ttl +153 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/midi/midi.ttl +366 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/morph/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/morph/morph.h +48 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/morph/morph.meta.ttl +90 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/morph/morph.ttl +46 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/options/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/options/options.h +149 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/options/options.meta.ttl +129 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/options/options.ttl +44 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/parameters/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/parameters/parameters.h +68 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/parameters/parameters.meta.ttl +75 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/parameters/parameters.ttl +202 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/patch/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/patch/patch.h +73 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/patch/patch.meta.ttl +374 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/patch/patch.ttl +251 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-groups/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-groups/port-groups.h +77 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-groups/port-groups.meta.ttl +144 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-groups/port-groups.ttl +807 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-props/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-props/port-props.h +53 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-props/port-props.meta.ttl +202 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/port-props/port-props.ttl +79 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/presets/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/presets/presets.h +48 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/presets/presets.meta.ttl +132 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/presets/presets.ttl +60 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/resize-port/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/resize-port/resize-port.h +89 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/resize-port/resize-port.meta.ttl +74 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/resize-port/resize-port.ttl +36 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/state/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/state/state.h +392 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/state/state.meta.ttl +467 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/state/state.ttl +60 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/time/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/time/time.h +59 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/time/time.meta.ttl +112 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/time/time.ttl +122 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/ui/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/ui/ui.h +543 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/ui/ui.meta.ttl +627 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/ui/ui.ttl +248 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/units/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/units/units.h +75 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/units/units.meta.ttl +154 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/units/units.ttl +379 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/uri-map/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/uri-map/uri-map.h +121 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/uri-map/uri-map.meta.ttl +72 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/uri-map/uri-map.ttl +14 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/urid/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/urid/urid.h +140 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/urid/urid.meta.ttl +84 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/urid/urid.ttl +22 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/worker/manifest.ttl +9 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/worker/worker.h +183 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/worker/worker.meta.ttl +82 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/lv2/lv2/worker/worker.ttl +25 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/COPYING +13 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/serd/serd.h +1059 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/.clang-tidy +18 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/attributes.h +26 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/base64.c +132 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/base64.h +48 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/byte_sink.h +98 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/byte_source.c +112 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/byte_source.h +120 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/env.c +256 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/n3.c +1720 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/node.c +393 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/node.h +48 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/reader.c +425 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/reader.h +196 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/serd_config.h +98 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/serd_internal.h +46 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/serdi.c +377 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/stack.h +119 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/string.c +179 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/string_utils.h +173 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/system.c +82 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/system.h +40 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/uri.c +506 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/uri_utils.h +110 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd/src/writer.c +1114 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/serd_config.h +42 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/COPYING +13 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/sord/sord.h +642 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/sord/sordmm.hpp +720 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sord.c +1368 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sord_config.h +61 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sord_internal.h +53 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sord_test.c +767 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sord_validate.c +804 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sordi.c +216 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/sordmm_test.cpp +25 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/syntax.c +203 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/btree.c +936 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/btree.h +187 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/common.h +138 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/digest.c +141 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/digest.h +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/hash.c +230 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord/src/zix/hash.h +138 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sord_config.h +42 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sratom/COPYING +13 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sratom/sratom/sratom.h +220 -0
- package/ios/juce_modules/juce_audio_processors/format_types/LV2_SDK/sratom/src/sratom.c +919 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/VST3_License_Agreement.pdf +0 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/VST3_Usage_Guidelines.pdf +0 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/baseiids.cpp +52 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/classfactoryhelpers.h +87 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.cpp +641 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fbuffer.h +306 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fcommandline.h +392 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.cpp +340 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fdebug.h +246 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.cpp +271 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fobject.h +577 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.cpp +756 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstreamer.h +242 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.cpp +3962 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/fstring.h +767 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.cpp +737 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/source/updatehandler.h +150 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/thread/include/flock.h +184 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/base/thread/source/flock.cpp +146 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/helper.manifest +10 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/conststringtable.cpp +106 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/conststringtable.h +44 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/coreiids.cpp +40 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/falignpop.h +25 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/falignpush.h +40 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fplatform.h +333 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fstrdefs.h +291 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ftypes.h +176 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/funknown.cpp +502 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/funknown.h +564 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/futils.h +107 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/fvariant.h +297 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ibstream.h +87 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/icloneable.h +41 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ipersistent.h +160 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ipluginbase.h +520 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/iplugincompatibility.h +122 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/istringresult.h +80 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/iupdatehandler.h +98 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/smartpointer.h +386 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/typesizecheck.h +55 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ustring.cpp +275 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/base/ustring.h +116 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugview.h +287 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/gui/iplugviewcontentscalesupport.h +75 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstattributes.h +150 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstaudioprocessor.h +434 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstautomationstate.h +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstchannelcontextinfo.h +238 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstcomponent.h +205 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstcontextmenu.h +219 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstdataexchange.h +221 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsteditcontroller.h +657 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstevents.h +221 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsthostapplication.h +163 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstinterappaudio.h +142 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstmessage.h +97 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstmidicontrollers.h +118 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstmidilearn.h +106 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstnoteexpression.h +255 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstparameterchanges.h +145 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstparameterfunctionname.h +151 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstphysicalui.h +169 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstpluginterfacesupport.h +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstplugview.h +62 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstprefetchablesupport.h +99 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstprocesscontext.h +153 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstremapparamid.h +75 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstrepresentation.h +364 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivsttestplugprovider.h +109 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/ivstunits.h +271 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstpshpack4.h +30 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vstspeaker.h +1318 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/pluginterfaces/vst/vsttypes.h +157 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/samples/vst-utilities/moduleinfotool/source/main.cpp +441 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.cpp +319 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/memorystream.h +79 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.cpp +100 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/pluginview.h +116 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.cpp +81 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/common/readfile.h +54 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.cpp +342 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/hostclasses.h +120 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.cpp +340 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module.h +214 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_linux.cpp +369 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_mac.mm +395 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/module_win32.cpp +647 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.cpp +134 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/hosting/pluginterfacesupport.h +70 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/json.h +3403 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/jsoncxx.h +427 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfo.h +100 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.cpp +309 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfocreator.h +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.cpp +537 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/moduleinfo/moduleinfoparser.h +68 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/optional.h +135 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.cpp +148 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/stringconvert.h +147 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/utility/uid.h +286 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.cpp +99 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstbus.h +172 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.cpp +216 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponent.h +118 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.cpp +180 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstcomponentbase.h +110 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.cpp +701 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vsteditcontroller.h +374 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstinitiids.cpp +154 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.cpp +454 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstparameters.h +240 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.cpp +927 -0
- package/ios/juce_modules/juce_audio_processors/format_types/VST3_SDK/public.sdk/source/vst/vstpresetfile.h +306 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_ARACommon.cpp +99 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_ARACommon.h +98 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_ARAHosting.cpp +490 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_ARAHosting.h +786 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_AU_Shared.h +588 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.h +79 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_AudioUnitPluginFormat.mm +2947 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LADSPAPluginFormat.cpp +728 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LADSPAPluginFormat.h +79 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2Common.h +676 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2PluginFormat.cpp +5654 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2PluginFormat.h +87 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2PluginFormat_test.cpp +281 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2Resources.h +10241 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LV2SupportLibs.cpp +117 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_LegacyAudioParameter.cpp +225 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VST3Common.h +1851 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VST3Headers.h +280 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp +4086 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VST3PluginFormat.h +95 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VST3PluginFormat_test.cpp +740 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VSTCommon.h +315 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VSTMidiEventList.h +229 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VSTPluginFormat.cpp +3764 -0
- package/ios/juce_modules/juce_audio_processors/format_types/juce_VSTPluginFormat.h +141 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipslcontextinfo.h +190 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipsleditcontroller.h +108 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipslgainreduction.h +53 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipslhostcommands.h +121 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipslviewembedding.h +53 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/ipslviewscaling.h +67 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/pslauextensions.h +57 -0
- package/ios/juce_modules/juce_audio_processors/format_types/pslextensions/pslvst2extensions.h +111 -0
- package/ios/juce_modules/juce_audio_processors/juce_audio_processors.cpp +246 -0
- package/ios/juce_modules/juce_audio_processors/juce_audio_processors.h +195 -0
- package/ios/juce_modules/juce_audio_processors/juce_audio_processors.mm +35 -0
- package/ios/juce_modules/juce_audio_processors/juce_audio_processors_ara.cpp +51 -0
- package/ios/juce_modules/juce_audio_processors/juce_audio_processors_lv2_libs.cpp +44 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioPluginInstance.cpp +294 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioPluginInstance.h +191 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessor.cpp +1655 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessor.h +1587 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorEditor.cpp +230 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorEditor.h +272 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorEditorHostContext.h +98 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorGraph.cpp +2375 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorGraph.h +453 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorListener.h +198 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorParameter.h +370 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorParameterGroup.cpp +330 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_AudioProcessorParameterGroup.h +263 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_GenericAudioProcessorEditor.cpp +633 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_GenericAudioProcessorEditor.h +74 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_HostedAudioProcessorParameter.h +61 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_PluginDescription.cpp +126 -0
- package/ios/juce_modules/juce_audio_processors/processors/juce_PluginDescription.h +189 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_KnownPluginList.cpp +651 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_KnownPluginList.h +249 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_PluginDirectoryScanner.cpp +148 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_PluginDirectoryScanner.h +147 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_PluginListComponent.cpp +690 -0
- package/ios/juce_modules/juce_audio_processors/scanning/juce_PluginListComponent.h +156 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARADebug.h +76 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARADocumentController.cpp +985 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARADocumentController.h +538 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARADocumentControllerCommon.cpp +80 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARAModelObjects.cpp +302 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARAModelObjects.h +983 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARAPlugInInstanceRoles.cpp +123 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARAPlugInInstanceRoles.h +263 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARA_utils.cpp +65 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_ARA_utils.h +95 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_AudioProcessor_ARAExtensions.cpp +163 -0
- package/ios/juce_modules/juce_audio_processors/utilities/ARA/juce_AudioProcessor_ARAExtensions.h +213 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AAXClientExtensions.cpp +308 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AAXClientExtensions.h +92 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterBool.cpp +104 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterBool.h +149 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterChoice.cpp +145 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterChoice.h +162 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterFloat.cpp +113 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterFloat.h +169 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterInt.cpp +146 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioParameterInt.h +163 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioProcessorParameterWithID.cpp +56 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioProcessorParameterWithID.h +200 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioProcessorValueTreeState.cpp +997 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_AudioProcessorValueTreeState.h +669 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_ExtensionsVisitor.h +155 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_FlagCache.h +191 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_ParameterAttachments.cpp +442 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_ParameterAttachments.h +400 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_PluginHostType.cpp +328 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_PluginHostType.h +265 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_RangedAudioParameter.cpp +60 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_RangedAudioParameter.h +129 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_VST2ClientExtensions.cpp +48 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_VST2ClientExtensions.h +83 -0
- package/ios/juce_modules/juce_audio_processors/utilities/juce_VST3ClientExtensions.h +119 -0
- package/ios/juce_modules/juce_core/native/juce_BasicNativeHeaders.h +6 -1
- package/ios/juce_modules/juce_graphics/colour/juce_Colour.cpp +726 -0
- package/ios/juce_modules/juce_graphics/colour/juce_Colour.h +429 -0
- package/ios/juce_modules/juce_graphics/colour/juce_ColourGradient.cpp +294 -0
- package/ios/juce_modules/juce_graphics/colour/juce_ColourGradient.h +255 -0
- package/ios/juce_modules/juce_graphics/colour/juce_Colours.cpp +205 -0
- package/ios/juce_modules/juce_graphics/colour/juce_Colours.h +200 -0
- package/ios/juce_modules/juce_graphics/colour/juce_FillType.cpp +166 -0
- package/ios/juce_modules/juce_graphics/colour/juce_FillType.h +165 -0
- package/ios/juce_modules/juce_graphics/colour/juce_PixelFormats.h +749 -0
- package/ios/juce_modules/juce_graphics/contexts/juce_GraphicsContext.cpp +857 -0
- package/ios/juce_modules/juce_graphics/contexts/juce_GraphicsContext.h +758 -0
- package/ios/juce_modules/juce_graphics/contexts/juce_LowLevelGraphicsContext.h +186 -0
- package/ios/juce_modules/juce_graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.cpp +59 -0
- package/ios/juce_modules/juce_graphics/contexts/juce_LowLevelGraphicsSoftwareRenderer.h +66 -0
- package/ios/juce_modules/juce_graphics/detail/juce_Ranges.cpp +793 -0
- package/ios/juce_modules/juce_graphics/detail/juce_Ranges.h +1014 -0
- package/ios/juce_modules/juce_graphics/effects/juce_DropShadowEffect.cpp +152 -0
- package/ios/juce_modules/juce_graphics/effects/juce_DropShadowEffect.h +122 -0
- package/ios/juce_modules/juce_graphics/effects/juce_GlowEffect.cpp +59 -0
- package/ios/juce_modules/juce_graphics/effects/juce_GlowEffect.h +86 -0
- package/ios/juce_modules/juce_graphics/effects/juce_ImageEffectFilter.h +80 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/CBDT/CBDT.hh +1031 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/COLR/COLR.hh +2745 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/COLR/colrv1-closure.hh +137 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/CPAL/CPAL.hh +358 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/sbix/sbix.hh +448 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Color/svg/svg.hh +152 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/Common/Coverage.hh +352 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/Common/CoverageFormat1.hh +133 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/Common/CoverageFormat2.hh +239 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/Common/RangeRecord.hh +97 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GDEF/GDEF.hh +1044 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/Anchor.hh +84 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/AnchorFormat1.hh +46 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/AnchorFormat2.hh +58 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/AnchorFormat3.hh +120 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/AnchorMatrix.hh +87 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/ChainContextPos.hh +14 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/Common.hh +33 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/ContextPos.hh +14 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/CursivePos.hh +35 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/CursivePosFormat1.hh +311 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/ExtensionPos.hh +17 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/GPOS.hh +171 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/LigatureArray.hh +57 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkArray.hh +128 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkBasePos.hh +41 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkBasePosFormat1.hh +243 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkLigPos.hh +41 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkLigPosFormat1.hh +224 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkMarkPos.hh +42 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkMarkPosFormat1.hh +231 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/MarkRecord.hh +51 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PairPos.hh +46 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PairPosFormat1.hh +233 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PairPosFormat2.hh +365 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PairSet.hh +210 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PairValueRecord.hh +99 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PosLookup.hh +79 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/PosLookupSubTable.hh +79 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/SinglePos.hh +98 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/SinglePosFormat1.hh +190 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/SinglePosFormat2.hh +213 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GPOS/ValueFormat.hh +441 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/AlternateSet.hh +126 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/AlternateSubst.hh +62 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/AlternateSubstFormat1.hh +128 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/ChainContextSubst.hh +18 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/Common.hh +19 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/ContextSubst.hh +18 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/ExtensionSubst.hh +22 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/GSUB.hh +61 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/Ligature.hh +203 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/LigatureSet.hh +188 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/LigatureSubst.hh +71 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/LigatureSubstFormat1.hh +166 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/MultipleSubst.hh +62 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/MultipleSubstFormat1.hh +130 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/ReverseChainSingleSubst.hh +36 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/ReverseChainSingleSubstFormat1.hh +245 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/Sequence.hh +165 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/SingleSubst.hh +103 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/SingleSubstFormat1.hh +204 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/SingleSubstFormat2.hh +176 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/SubstLookup.hh +220 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/GSUB/SubstLookupSubTable.hh +77 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Layout/types.hh +66 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Var/VARC/VARC.cc +346 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Var/VARC/VARC.hh +193 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/Var/VARC/coord-setter.hh +37 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/CompositeGlyph.hh +435 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/Glyph.hh +556 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/GlyphHeader.hh +52 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/SimpleGlyph.hh +348 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/SubsetGlyph.hh +141 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/composite-iter.hh +68 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/glyf-helpers.hh +127 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/glyf.hh +513 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/loca.hh +43 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/glyf/path-builder.hh +190 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/OT/name/name.hh +589 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/failing-alloc.c +65 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/harfbuzz-subset.cc +64 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/harfbuzz.cc +63 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-ankr-table.hh +99 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-bsln-table.hh +159 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-common.hh +1076 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-feat-table.hh +224 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-just-table.hh +420 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-kerx-table.hh +1191 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-morx-table.hh +1443 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-opbd-table.hh +174 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout-trak-table.hh +232 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout.cc +449 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout.h +795 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-layout.hh +77 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-ltag-table.hh +95 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-map.cc +172 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat-map.hh +123 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-aat.h +38 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-algs.hh +1558 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-array.hh +504 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-atomic.hh +228 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-bimap.hh +205 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-bit-page.hh +352 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-bit-set-invertible.hh +379 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-bit-set.hh +982 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-blob.cc +794 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-blob.h +160 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-blob.hh +98 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer-deserialize-json.hh +795 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer-deserialize-text-glyphs.hh +692 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer-deserialize-text-unicode.hh +332 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer-serialize.cc +872 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer-verify.cc +423 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer.cc +2266 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer.h +805 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-buffer.hh +682 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cache.hh +99 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cff-interp-common.hh +642 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cff-interp-cs-common.hh +905 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cff-interp-dict-common.hh +201 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cff1-interp-cs.hh +160 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cff2-interp-cs.hh +278 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-common.cc +1220 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-common.h +935 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-config.hh +212 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-coretext.cc +1197 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-coretext.h +96 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-cplusplus.hh +220 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-debug.hh +491 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-deprecated.h +318 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-directwrite.cc +884 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-directwrite.h +40 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-dispatch.hh +60 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-draw.cc +458 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-draw.h +340 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-draw.hh +243 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-face-builder.cc +246 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-face.cc +664 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-face.h +187 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-face.hh +111 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-fallback-shape.cc +115 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-font.cc +3069 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-font.h +1153 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-font.hh +720 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ft-colr.hh +601 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ft.cc +1500 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ft.h +145 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-gdi.cc +85 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-gdi.h +39 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-geometry.hh +284 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-glib.cc +232 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-glib.h +56 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-gobject-structs.cc +116 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-gobject-structs.h +136 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-gobject.h +40 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-graphite2.cc +455 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-graphite2.h +61 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-icu.cc +291 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-icu.h +52 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-iter.hh +1037 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-kern.hh +145 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-limits.hh +112 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-machinery.hh +332 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-map.cc +419 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-map.h +143 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-map.hh +568 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-meta.hh +238 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ms-feature-ranges.hh +232 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-multimap.hh +96 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-mutex.hh +122 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-null.hh +226 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-number-parser.hh +237 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-number.cc +79 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-number.hh +41 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-object.hh +357 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-open-file.hh +543 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-open-type.hh +1886 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff-common.hh +374 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff1-std-str.hh +425 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff1-table.cc +620 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff1-table.hh +1539 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff2-table.cc +227 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cff2-table.hh +564 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-cmap-table.hh +2154 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-color.cc +363 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-color.h +155 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-deprecated.h +147 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-face-table-list.hh +155 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-face.cc +60 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-face.hh +77 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-font.cc +662 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-font.h +45 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-gasp-table.hh +84 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-glyf-table.hh +35 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-hdmx-table.hh +177 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-head-table.hh +204 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-hhea-table.hh +106 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-hmtx-table.hh +502 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-kern-table.hh +425 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-base-table.hh +849 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-common.hh +4953 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-gdef-table.hh +34 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-gpos-table.hh +81 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-gsub-table.hh +94 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-gsubgpos.hh +4887 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout-jstf-table.hh +236 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout.cc +2705 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout.h +549 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-layout.hh +611 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-map.cc +394 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-map.hh +298 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-math-table.hh +1132 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-math.cc +338 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-math.h +333 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-maxp-table.hh +156 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-meta-table.hh +131 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-meta.cc +79 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-meta.h +72 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-metrics.cc +436 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-metrics.h +129 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-metrics.hh +35 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-name-language-static.hh +456 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-name-language.hh +40 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-name-table.hh +32 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-name.cc +184 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-name.h +164 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-os2-table.hh +405 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-os2-unicode-ranges.hh +231 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-post-macroman.hh +294 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-post-table-v2subset.hh +142 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-post-table.hh +352 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape-fallback.cc +615 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape-fallback.hh +54 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape-normalize.cc +470 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape-normalize.hh +104 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape.cc +1319 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape.h +53 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shape.hh +171 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic-fallback.hh +383 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic-joining-list.hh +47 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic-pua.hh +118 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic-table.hh +556 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic-win1256.hh +349 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic.cc +774 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-arabic.hh +50 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-default.cc +75 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-hangul.cc +436 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-hebrew.cc +211 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-indic-machine.hh +627 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-indic-table.cc +561 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-indic.cc +1578 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-indic.hh +66 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-khmer-machine.hh +428 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-khmer.cc +387 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-myanmar-machine.hh +553 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-myanmar.cc +390 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-syllabic.cc +112 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-syllabic.hh +47 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-thai.cc +393 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-use-machine.hh +1079 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-use-table.hh +690 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-use.cc +514 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-vowel-constraints.cc +477 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper-vowel-constraints.hh +39 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-shaper.hh +404 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-stat-table.hh +619 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-tag-table.hh +3009 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-tag.cc +658 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-avar-table.hh +411 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-common.hh +1985 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-cvar-table.hh +220 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-fvar-table.hh +505 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-gvar-table.hh +890 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-hvar-table.hh +478 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-mvar-table.hh +184 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var-varc-table.hh +32 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var.cc +328 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-var.h +191 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot-vorg-table.hh +137 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ot.h +49 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-outline.cc +321 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-outline.hh +83 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-paint-extents.cc +330 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-paint-extents.hh +132 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-paint.cc +728 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-paint.h +1029 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-paint.hh +236 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-pool.hh +107 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-priority-queue.hh +174 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-repacker.hh +476 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-sanitize.hh +530 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-serialize.hh +832 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-set-digest.hh +227 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-set.cc +673 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-set.h +203 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-set.hh +186 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shape-plan.cc +581 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shape-plan.h +122 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shape-plan.hh +77 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shape.cc +445 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shape.h +74 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shaper-impl.hh +38 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shaper-list.hh +65 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shaper.cc +102 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-shaper.hh +134 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-static.cc +138 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-string-array.hh +85 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-style.cc +134 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-style.h +81 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-accelerator.hh +141 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-cff-common.cc +231 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-cff-common.hh +1228 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-cff1.cc +1001 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-cff2.cc +679 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-input.cc +748 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-input.hh +155 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-instancer-iup.cc +532 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-instancer-iup.hh +37 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-instancer-solver.cc +434 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-instancer-solver.hh +114 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-plan-member-list.hh +164 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-plan.cc +1570 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-plan.hh +302 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-repacker.cc +58 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset-repacker.h +81 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset.cc +704 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset.h +260 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-subset.hh +74 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ucd-table.hh +5637 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-ucd.cc +258 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-unicode-emoji-table.hh +79 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-unicode.cc +625 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-unicode.h +643 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-unicode.hh +403 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-uniscribe.cc +889 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-uniscribe.h +46 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-utf.hh +481 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-vector.hh +539 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-version.h +95 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-blob.hh +50 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-buffer.hh +217 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-common.hh +44 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-face.hh +109 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-font.hh +263 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-list.hh +109 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api-shape.hh +70 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api.cc +46 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api.h +322 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-api.hh +117 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb-wasm-shape.cc +470 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb.h +51 -0
- package/ios/juce_modules/juce_graphics/fonts/harfbuzz/hb.hh +555 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_AttributedString.cpp +288 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_AttributedString.h +219 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_Font.cpp +1036 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_Font.h +571 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_FontOptions.cpp +111 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_FontOptions.h +218 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_FunctionPointerDestructor.h +53 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_GlyphArrangement.cpp +657 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_GlyphArrangement.h +324 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_JustifiedText.cpp +580 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_LruCache.h +88 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_ShapedText.cpp +210 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_SimpleShapedText.cpp +1279 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_TextLayout.cpp +512 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_TextLayout.h +278 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_Typeface.cpp +983 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_Typeface.h +396 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_TypefaceFileCache.h +74 -0
- package/ios/juce_modules/juce_graphics/fonts/juce_TypefaceTestData.cpp +6051 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_AffineTransform.cpp +307 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_AffineTransform.h +314 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_BorderSize.h +176 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_EdgeTable.cpp +848 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_EdgeTable.h +225 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Line.h +454 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Parallelogram.h +194 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Parallelogram_test.cpp +75 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Path.cpp +1531 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Path.h +846 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_PathIterator.cpp +304 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_PathIterator.h +120 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_PathStrokeType.cpp +756 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_PathStrokeType.h +215 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Point.h +269 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Rectangle.h +1032 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_RectangleList.h +694 -0
- package/ios/juce_modules/juce_graphics/geometry/juce_Rectangle_test.cpp +60 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/README +385 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/cderror.h +132 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcapimin.c +280 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcapistd.c +161 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jccoefct.c +449 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jccolor.c +459 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcdctmgr.c +387 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jchuff.c +909 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jchuff.h +52 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcinit.c +72 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcmainct.c +293 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcmarker.c +597 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcmaster.c +590 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcomapi.c +106 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jconfig.h +59 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcparam.c +610 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcphuff.c +833 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcprepct.c +354 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jcsample.c +519 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jctrans.c +388 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdapimin.c +395 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdapistd.c +275 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdatasrc.c +212 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdcoefct.c +736 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdcolor.c +396 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdct.h +182 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jddctmgr.c +269 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdhuff.c +625 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdhuff.h +206 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdinput.c +381 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdmainct.c +512 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdmarker.c +1292 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdmaster.c +557 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdmerge.c +400 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdphuff.c +642 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdpostct.c +290 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdsample.c +478 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jdtrans.c +143 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jerror.c +252 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jerror.h +291 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jfdctflt.c +168 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jfdctfst.c +224 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jfdctint.c +283 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jidctflt.c +242 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jidctfst.c +368 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jidctint.c +389 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jidctred.c +398 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jinclude.h +197 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jmemmgr.c +1118 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jmemnobs.c +109 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jmemsys.h +203 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jmorecfg.h +363 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jpegint.h +392 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jpeglib.h +1096 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jquant1.c +856 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jquant2.c +1310 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jutils.c +179 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/jversion.h +14 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/transupp.c +928 -0
- package/ios/juce_modules/juce_graphics/image_formats/jpglib/transupp.h +135 -0
- package/ios/juce_modules/juce_graphics/image_formats/juce_GIFLoader.cpp +464 -0
- package/ios/juce_modules/juce_graphics/image_formats/juce_JPEGLoader.cpp +456 -0
- package/ios/juce_modules/juce_graphics/image_formats/juce_PNGLoader.cpp +635 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/png.c +4607 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/png.h +3251 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngconf.h +623 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngdebug.h +153 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngerror.c +963 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngget.c +1249 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pnginfo.h +267 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngmem.c +284 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngpread.c +1096 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngpriv.h +2156 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngread.c +4225 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngrio.c +120 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngrtran.c +5102 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngrutil.c +4681 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngset.c +1802 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngstruct.h +491 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngtrans.c +864 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngwio.c +168 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngwrite.c +2395 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngwtran.c +587 -0
- package/ios/juce_modules/juce_graphics/image_formats/pnglib/pngwutil.c +2781 -0
- package/ios/juce_modules/juce_graphics/images/juce_Image.cpp +851 -0
- package/ios/juce_modules/juce_graphics/images/juce_Image.h +630 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageCache.cpp +183 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageCache.h +136 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageConvolutionKernel.cpp +209 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageConvolutionKernel.h +121 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageFileFormat.cpp +120 -0
- package/ios/juce_modules/juce_graphics/images/juce_ImageFileFormat.h +232 -0
- package/ios/juce_modules/juce_graphics/images/juce_ScaledImage.h +93 -0
- package/ios/juce_modules/juce_graphics/juce_graphics.cpp +230 -0
- package/ios/juce_modules/juce_graphics/juce_graphics.h +162 -0
- package/ios/juce_modules/juce_graphics/juce_graphics.mm +35 -0
- package/ios/juce_modules/juce_graphics/juce_graphics_Harfbuzz.cpp +100 -0
- package/ios/juce_modules/juce_graphics/native/juce_CoreGraphicsContext_mac.h +153 -0
- package/ios/juce_modules/juce_graphics/native/juce_CoreGraphicsContext_mac.mm +969 -0
- package/ios/juce_modules/juce_graphics/native/juce_CoreGraphicsHelpers_mac.h +117 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DGraphicsContext_windows.cpp +1807 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DGraphicsContext_windows.h +174 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DHelpers_windows.cpp +456 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DHwndContext_windows.cpp +784 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DHwndContext_windows.h +73 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DImageContext_windows.cpp +124 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DImageContext_windows.h +55 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DImage_windows.cpp +732 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DImage_windows.h +94 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DMetrics_windows.cpp +132 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DMetrics_windows.h +320 -0
- package/ios/juce_modules/juce_graphics/native/juce_Direct2DResources_windows.cpp +661 -0
- package/ios/juce_modules/juce_graphics/native/juce_DirectWriteTypeface_windows.cpp +920 -0
- package/ios/juce_modules/juce_graphics/native/juce_DirectX_windows.h +330 -0
- package/ios/juce_modules/juce_graphics/native/juce_EventTracing.h +310 -0
- package/ios/juce_modules/juce_graphics/native/juce_Fonts_android.cpp +636 -0
- package/ios/juce_modules/juce_graphics/native/juce_Fonts_freetype.cpp +589 -0
- package/ios/juce_modules/juce_graphics/native/juce_Fonts_linux.cpp +208 -0
- package/ios/juce_modules/juce_graphics/native/juce_Fonts_mac.mm +416 -0
- package/ios/juce_modules/juce_graphics/native/juce_GraphicsContext_android.cpp +43 -0
- package/ios/juce_modules/juce_graphics/native/juce_IconHelpers_android.cpp +39 -0
- package/ios/juce_modules/juce_graphics/native/juce_IconHelpers_linux.cpp +39 -0
- package/ios/juce_modules/juce_graphics/native/juce_IconHelpers_mac.cpp +150 -0
- package/ios/juce_modules/juce_graphics/native/juce_IconHelpers_windows.cpp +39 -0
- package/ios/juce_modules/juce_graphics/native/juce_RenderingHelpers.h +2696 -0
- package/ios/juce_modules/juce_graphics/placement/juce_Justification.h +196 -0
- package/ios/juce_modules/juce_graphics/placement/juce_RectanglePlacement.cpp +131 -0
- package/ios/juce_modules/juce_graphics/placement/juce_RectanglePlacement.h +183 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_Unicode.cpp +331 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeBidi.cpp +1139 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeBrackets.cpp +142 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeGenerated.cpp +1380 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeLine.cpp +273 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeScript.cpp +235 -0
- package/ios/juce_modules/juce_graphics/unicode/juce_UnicodeUtils.cpp +104 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/enums/juce_AccessibilityActions.h +128 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/enums/juce_AccessibilityEvent.h +90 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/enums/juce_AccessibilityRole.h +80 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/interfaces/juce_AccessibilityCellInterface.h +61 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/interfaces/juce_AccessibilityTableInterface.h +106 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/interfaces/juce_AccessibilityTextInterface.h +93 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/interfaces/juce_AccessibilityValueInterface.h +231 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/juce_AccessibilityHandler.cpp +412 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/juce_AccessibilityHandler.h +354 -0
- package/ios/juce_modules/juce_gui_basics/accessibility/juce_AccessibilityState.h +236 -0
- package/ios/juce_modules/juce_gui_basics/application/juce_Application.cpp +109 -0
- package/ios/juce_modules/juce_gui_basics/application/juce_Application.h +202 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ArrowButton.cpp +60 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ArrowButton.h +74 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_Button.cpp +730 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_Button.h +559 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_DrawableButton.cpp +250 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_DrawableButton.h +206 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_HyperlinkButton.cpp +138 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_HyperlinkButton.h +139 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ImageButton.cpp +207 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ImageButton.h +170 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ShapeButton.cpp +146 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ShapeButton.h +135 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_TextButton.cpp +86 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_TextButton.h +118 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ToggleButton.cpp +74 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ToggleButton.h +102 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ToolbarButton.cpp +122 -0
- package/ios/juce_modules/juce_gui_basics/buttons/juce_ToolbarButton.h +107 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandID.h +99 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandInfo.cpp +75 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandInfo.h +199 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandManager.cpp +331 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandManager.h +358 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandTarget.cpp +195 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_ApplicationCommandTarget.h +253 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_KeyPressMappingSet.cpp +427 -0
- package/ios/juce_modules/juce_gui_basics/commands/juce_KeyPressMappingSet.h +253 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_CachedComponentImage.h +81 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_Component.cpp +3013 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_Component.h +2716 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_ComponentListener.cpp +47 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_ComponentListener.h +131 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_ComponentTraverser.h +81 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_FocusTraverser.cpp +283 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_FocusTraverser.h +102 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_ModalComponentManager.cpp +295 -0
- package/ios/juce_modules/juce_gui_basics/components/juce_ModalComponentManager.h +340 -0
- package/ios/juce_modules/juce_gui_basics/desktop/juce_Desktop.cpp +386 -0
- package/ios/juce_modules/juce_gui_basics/desktop/juce_Desktop.h +502 -0
- package/ios/juce_modules/juce_gui_basics/desktop/juce_Displays.cpp +447 -0
- package/ios/juce_modules/juce_gui_basics/desktop/juce_Displays.h +218 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_AccessibilityHelpers.cpp +42 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_AccessibilityHelpers.h +79 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_AlertWindowHelpers.h +124 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ButtonAccessibilityHandler.h +134 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ComponentHelpers.h +291 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_CustomMouseCursorInfo.h +44 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_FocusHelpers.h +126 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_FocusRestorer.h +55 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_LookAndFeelHelpers.h +71 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_MouseInputSourceImpl.h +597 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_MouseInputSourceList.h +163 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_PointerState.h +113 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ScalingHelpers.h +132 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ScopedContentSharerImpl.h +107 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ScopedContentSharerInterface.h +224 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ScopedMessageBoxImpl.h +141 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ScopedMessageBoxInterface.h +69 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_StandardCachedComponentImage.h +102 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ToolbarItemDragAndDropOverlayComponent.h +127 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_TopLevelWindowManager.h +145 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_ViewportHelpers.h +58 -0
- package/ios/juce_modules/juce_gui_basics/detail/juce_WindowingHelpers.h +70 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_Drawable.cpp +228 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_Drawable.h +271 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableComposite.cpp +173 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableComposite.h +126 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableImage.cpp +165 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableImage.h +126 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawablePath.cpp +66 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawablePath.h +86 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableRectangle.cpp +96 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableRectangle.h +85 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableShape.cpp +190 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableShape.h +135 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableText.cpp +241 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_DrawableText.h +130 -0
- package/ios/juce_modules/juce_gui_basics/drawables/juce_SVGParser.cpp +1903 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_ContentSharer.cpp +83 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_ContentSharer.h +154 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_DirectoryContentsDisplayComponent.cpp +79 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_DirectoryContentsDisplayComponent.h +125 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_DirectoryContentsList.cpp +279 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_DirectoryContentsList.h +235 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileBrowserComponent.cpp +633 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileBrowserComponent.h +306 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileBrowserListener.h +67 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileChooser.cpp +292 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileChooser.h +358 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.cpp +272 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileChooserDialogBox.h +177 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileListComponent.cpp +295 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileListComponent.h +104 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FilePreviewComponent.h +75 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileSearchPathListComponent.cpp +280 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileSearchPathListComponent.h +126 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileTreeComponent.cpp +690 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FileTreeComponent.h +117 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FilenameComponent.cpp +277 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_FilenameComponent.h +245 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_ImagePreviewComponent.cpp +135 -0
- package/ios/juce_modules/juce_gui_basics/filebrowser/juce_ImagePreviewComponent.h +77 -0
- package/ios/juce_modules/juce_gui_basics/juce_gui_basics.cpp +370 -0
- package/ios/juce_modules/juce_gui_basics/juce_gui_basics.h +403 -0
- package/ios/juce_modules/juce_gui_basics/juce_gui_basics.mm +35 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_CaretComponent.cpp +73 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_CaretComponent.h +90 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyListener.cpp +43 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyListener.h +86 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyPress.cpp +298 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyPress.h +286 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyboardFocusTraverser.cpp +283 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_KeyboardFocusTraverser.h +96 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_ModifierKeys.cpp +58 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_ModifierKeys.h +220 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_SystemClipboard.h +58 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_TextEditorKeyMapper.h +132 -0
- package/ios/juce_modules/juce_gui_basics/keyboard/juce_TextInputTarget.h +129 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_AnimatedPosition.h +216 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_AnimatedPositionBehaviours.h +162 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_BorderedComponentBoundsConstrainer.cpp +86 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_BorderedComponentBoundsConstrainer.h +78 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentAnimator.cpp +363 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentAnimator.h +174 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentBoundsConstrainer.cpp +314 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentBoundsConstrainer.h +206 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentBuilder.cpp +295 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentBuilder.h +256 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentMovementWatcher.cpp +151 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ComponentMovementWatcher.h +105 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ConcertinaPanel.cpp +512 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ConcertinaPanel.h +153 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_FlexBox.cpp +1158 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_FlexBox.h +152 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_FlexItem.h +186 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_Grid.cpp +1651 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_Grid.h +232 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_GridItem.cpp +188 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_GridItem.h +249 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_GroupComponent.cpp +87 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_GroupComponent.h +120 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_MultiDocumentPanel.cpp +641 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_MultiDocumentPanel.h +390 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableBorderComponent.cpp +208 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableBorderComponent.h +205 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableCornerComponent.cpp +112 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableCornerComponent.h +101 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableEdgeComponent.cpp +139 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ResizableEdgeComponent.h +109 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ScrollBar.cpp +486 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_ScrollBar.h +450 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_SidePanel.cpp +309 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_SidePanel.h +248 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableLayoutManager.cpp +351 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableLayoutManager.h +270 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableLayoutResizerBar.cpp +88 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableLayoutResizerBar.h +114 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableObjectResizer.cpp +131 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_StretchableObjectResizer.h +111 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_TabbedButtonBar.cpp +592 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_TabbedButtonBar.h +382 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_TabbedComponent.cpp +328 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_TabbedComponent.h +236 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_Viewport.cpp +649 -0
- package/ios/juce_modules/juce_gui_basics/layout/juce_Viewport.h +383 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel.cpp +201 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel.h +301 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V1.cpp +599 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V1.h +114 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V2.cpp +3200 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V2.h +443 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V3.cpp +655 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V3.h +107 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V4.cpp +1516 -0
- package/ios/juce_modules/juce_gui_basics/lookandfeel/juce_LookAndFeel_V4.h +269 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_BurgerMenuComponent.cpp +311 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_BurgerMenuComponent.h +120 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_MenuBarComponent.cpp +472 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_MenuBarComponent.h +138 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_MenuBarModel.cpp +108 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_MenuBarModel.h +201 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_PopupMenu.cpp +2401 -0
- package/ios/juce_modules/juce_gui_basics/menus/juce_PopupMenu.h +1070 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_BubbleComponent.cpp +162 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_BubbleComponent.h +213 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_DropShadower.cpp +408 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_DropShadower.h +96 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_FocusOutline.cpp +194 -0
- package/ios/juce_modules/juce_gui_basics/misc/juce_FocusOutline.h +109 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_ComponentDragger.cpp +76 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_ComponentDragger.h +110 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_DragAndDropContainer.cpp +646 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_DragAndDropContainer.h +275 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_DragAndDropTarget.h +149 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_FileDragAndDropTarget.h +115 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_LassoComponent.h +233 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseCursor.cpp +162 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseCursor.h +199 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseEvent.cpp +147 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseEvent.h +463 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseInactivityDetector.cpp +86 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseInactivityDetector.h +121 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseInputSource.cpp +114 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseInputSource.h +315 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseListener.cpp +48 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_MouseListener.h +180 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_SelectedItemSet.h +336 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_TextDragAndDropTarget.h +115 -0
- package/ios/juce_modules/juce_gui_basics/mouse/juce_TooltipClient.h +98 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_Accessibility.cpp +46 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_AccessibilityElement_windows.cpp +660 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_AccessibilityElement_windows.h +89 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_AccessibilitySharedCode_mac.mm +283 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_AccessibilityTextHelpers.h +311 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_AccessibilityTextHelpers_test.cpp +164 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_Accessibility_android.cpp +1058 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_Accessibility_ios.mm +669 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_Accessibility_mac.mm +942 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_Accessibility_windows.cpp +336 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAExpandCollapseProvider_windows.h +92 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAGridItemProvider_windows.h +162 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAGridProvider_windows.h +160 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAHelpers_windows.h +128 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAInvokeProvider_windows.h +68 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAProviderBase_windows.h +67 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAProviders_windows.h +52 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIARangeValueProvider_windows.h +146 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIASelectionProvider_windows.h +254 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIATextProvider_windows.h +626 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAToggleProvider_windows.h +87 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIATransformProvider_windows.h +131 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAValueProvider_windows.h +92 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_UIAWindowProvider_windows.h +203 -0
- package/ios/juce_modules/juce_gui_basics/native/accessibility/juce_WindowsUIAWrapper_windows.h +169 -0
- package/ios/juce_modules/juce_gui_basics/native/java/app/com/rmsl/juce/ComponentPeerView.java +987 -0
- package/ios/juce_modules/juce_gui_basics/native/java/app/com/rmsl/juce/JuceContentProviderCursor.java +62 -0
- package/ios/juce_modules/juce_gui_basics/native/java/app/com/rmsl/juce/JuceContentProviderFileObserver.java +57 -0
- package/ios/juce_modules/juce_gui_basics/native/javaopt/app/com/rmsl/juce/JuceActivity.java +63 -0
- package/ios/juce_modules/juce_gui_basics/native/javaopt/app/com/rmsl/juce/JuceSharingContentProvider.java +128 -0
- package/ios/juce_modules/juce_gui_basics/native/javaopt/app/com/rmsl/juce/Receiver.java +51 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_CGMetalLayerRenderer_mac.h +384 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ContentSharer_android.cpp +963 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ContentSharer_ios.cpp +134 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_DragAndDrop_linux.cpp +618 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_DragAndDrop_windows.cpp +377 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_FileChooser_android.cpp +276 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_FileChooser_ios.mm +379 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_FileChooser_linux.cpp +296 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_FileChooser_mac.mm +414 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_FileChooser_windows.cpp +908 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_MainMenu_mac.mm +848 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_MouseCursor_mac.mm +205 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_MultiTouchMapper.h +116 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NSViewComponentPeer_mac.mm +3053 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeMessageBox_android.cpp +124 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeMessageBox_ios.mm +119 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeMessageBox_linux.cpp +78 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeMessageBox_mac.mm +140 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeMessageBox_windows.cpp +354 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_NativeModalWrapperComponent_ios.h +141 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_PerScreenDisplayLinks_mac.h +313 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ScopedDPIAwarenessDisabler.cpp +43 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ScopedDPIAwarenessDisabler.h +63 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ScopedThreadDPIAwarenessSetter_windows.h +52 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_ScopedWindowAssociation_linux.h +127 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_UIViewComponentPeer_ios.mm +2376 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_VBlank_windows.cpp +302 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowUtils_android.cpp +43 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowUtils_ios.mm +43 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowUtils_linux.cpp +48 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowUtils_mac.mm +47 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowUtils_windows.cpp +68 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_Windowing_android.cpp +2903 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_Windowing_ios.mm +629 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_Windowing_linux.cpp +863 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_Windowing_mac.mm +588 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_Windowing_windows.cpp +5549 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowsHooks_windows.cpp +118 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_WindowsHooks_windows.h +55 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_XSymbols_linux.cpp +249 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_XSymbols_linux.h +629 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_XWindowSystem_linux.cpp +4036 -0
- package/ios/juce_modules/juce_gui_basics/native/juce_XWindowSystem_linux.h +364 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_MarkerList.cpp +293 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_MarkerList.h +204 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeCoordinate.cpp +162 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeCoordinate.h +190 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeCoordinatePositioner.cpp +344 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeCoordinatePositioner.h +99 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeParallelogram.cpp +149 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeParallelogram.h +75 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativePoint.cpp +110 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativePoint.h +100 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativePointPath.cpp +271 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativePointPath.h +202 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeRectangle.cpp +286 -0
- package/ios/juce_modules/juce_gui_basics/positioning/juce_RelativeRectangle.h +117 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_BooleanPropertyComponent.cpp +95 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_BooleanPropertyComponent.h +118 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_ButtonPropertyComponent.cpp +55 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_ButtonPropertyComponent.h +85 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_ChoicePropertyComponent.cpp +284 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_ChoicePropertyComponent.h +162 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_MultiChoicePropertyComponent.cpp +367 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_MultiChoicePropertyComponent.h +150 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_PropertyComponent.cpp +65 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_PropertyComponent.h +154 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_PropertyPanel.cpp +405 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_PropertyPanel.h +186 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_SliderPropertyComponent.cpp +95 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_SliderPropertyComponent.h +116 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_TextPropertyComponent.cpp +271 -0
- package/ios/juce_modules/juce_gui_basics/properties/juce_TextPropertyComponent.h +196 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ComboBox.cpp +721 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ComboBox.h +473 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ImageComponent.cpp +116 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ImageComponent.h +90 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Label.cpp +592 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Label.h +377 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ListBox.cpp +1263 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ListBox.h +656 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ProgressBar.cpp +189 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ProgressBar.h +215 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Slider.cpp +1839 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Slider.h +1048 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TableHeaderComponent.cpp +935 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TableHeaderComponent.h +472 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TableListBox.cpp +688 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TableListBox.h +365 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TextEditor.cpp +2786 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TextEditor.h +888 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Toolbar.cpp +838 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_Toolbar.h +347 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ToolbarItemComponent.cpp +173 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ToolbarItemComponent.h +217 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ToolbarItemFactory.h +118 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ToolbarItemPalette.cpp +125 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_ToolbarItemPalette.h +88 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TreeView.cpp +2286 -0
- package/ios/juce_modules/juce_gui_basics/widgets/juce_TreeView.h +969 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_AlertWindow.cpp +712 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_AlertWindow.h +600 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_CallOutBox.cpp +279 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_CallOutBox.h +197 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ComponentPeer.cpp +625 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ComponentPeer.h +623 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_DialogWindow.cpp +190 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_DialogWindow.h +286 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_DocumentWindow.cpp +423 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_DocumentWindow.h +316 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_MessageBoxOptions.cpp +102 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_MessageBoxOptions.h +202 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_NativeMessageBox.cpp +167 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_NativeMessageBox.h +311 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_NativeScaleFactorNotifier.cpp +75 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_NativeScaleFactorNotifier.h +78 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ResizableWindow.cpp +679 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ResizableWindow.h +427 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ScopedMessageBox.cpp +67 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ScopedMessageBox.h +78 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ThreadWithProgressWindow.cpp +128 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_ThreadWithProgressWindow.h +184 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_TooltipWindow.cpp +264 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_TooltipWindow.h +169 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_TopLevelWindow.cpp +264 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_TopLevelWindow.h +176 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_VBlankAttachment.cpp +122 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_VBlankAttachment.h +85 -0
- package/ios/juce_modules/juce_gui_basics/windows/juce_WindowUtils.h +51 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CPlusPlusCodeTokeniser.cpp +83 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CPlusPlusCodeTokeniser.h +81 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CPlusPlusCodeTokeniserFunctions.h +683 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CodeDocument.cpp +1306 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CodeDocument.h +459 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CodeEditorComponent.cpp +1857 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CodeEditorComponent.h +486 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_CodeTokeniser.h +68 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_LuaCodeTokeniser.cpp +248 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_LuaCodeTokeniser.h +74 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_XMLCodeTokeniser.cpp +181 -0
- package/ios/juce_modules/juce_gui_extra/code_editor/juce_XMLCodeTokeniser.h +72 -0
- package/ios/juce_modules/juce_gui_extra/detail/juce_WebControlRelayEvents.h +255 -0
- package/ios/juce_modules/juce_gui_extra/documents/juce_FileBasedDocument.cpp +1124 -0
- package/ios/juce_modules/juce_gui_extra/documents/juce_FileBasedDocument.h +440 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_ActiveXControlComponent.h +142 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_AndroidViewComponent.h +91 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_HWNDComponent.h +98 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_NSViewComponent.h +107 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_UIViewComponent.h +99 -0
- package/ios/juce_modules/juce_gui_extra/embedding/juce_XEmbedComponent.h +129 -0
- package/ios/juce_modules/juce_gui_extra/juce_gui_extra.cpp +210 -0
- package/ios/juce_modules/juce_gui_extra/juce_gui_extra.h +161 -0
- package/ios/juce_modules/juce_gui_extra/juce_gui_extra.mm +35 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_AnimatedAppComponent.cpp +89 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_AnimatedAppComponent.h +96 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_AppleRemote.h +126 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_BubbleMessageComponent.cpp +133 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_BubbleMessageComponent.h +134 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_ColourSelector.cpp +656 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_ColourSelector.h +173 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_KeyMappingEditorComponent.cpp +486 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_KeyMappingEditorComponent.h +142 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_LiveConstantEditor.cpp +501 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_LiveConstantEditor.h +310 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_PreferencesPanel.cpp +165 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_PreferencesPanel.h +156 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_PushNotifications.cpp +239 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_PushNotifications.h +714 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_RecentlyOpenedFilesList.cpp +189 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_RecentlyOpenedFilesList.h +186 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_SplashScreen.cpp +110 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_SplashScreen.h +165 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_SystemTrayIconComponent.cpp +51 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_SystemTrayIconComponent.h +125 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_WebBrowserComponent.cpp +722 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_WebBrowserComponent.h +626 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_WebControlParameterIndexReceiver.h +76 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_WebControlRelays.cpp +256 -0
- package/ios/juce_modules/juce_gui_extra/misc/juce_WebControlRelays.h +254 -0
- package/ios/juce_modules/juce_gui_extra/native/java/app/com/rmsl/juce/JuceWebViewClasses.java +356 -0
- package/ios/juce_modules/juce_gui_extra/native/javaopt/app/com/rmsl/juce/JuceFirebaseInstanceIdService.java +50 -0
- package/ios/juce_modules/juce_gui_extra/native/javaopt/app/com/rmsl/juce/JuceFirebaseMessagingService.java +69 -0
- package/ios/juce_modules/juce_gui_extra/native/javascript/check_native_interop.js +146 -0
- package/ios/juce_modules/juce_gui_extra/native/javascript/index.js +577 -0
- package/ios/juce_modules/juce_gui_extra/native/javascript/package.json +4 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_ActiveXComponent_windows.cpp +553 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_AndroidViewComponent.cpp +199 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_AppleRemote_mac.mm +285 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_HWNDComponent_windows.cpp +203 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_NSViewComponent_mac.mm +203 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_NSViewFrameWatcher_mac.h +120 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_PushNotifications_android.cpp +1607 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_PushNotifications_ios.cpp +620 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_PushNotifications_mac.cpp +535 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_SystemTrayIcon_linux.cpp +160 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_SystemTrayIcon_mac.cpp +451 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_SystemTrayIcon_windows.cpp +251 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_UIViewComponent_ios.mm +151 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_WebBrowserComponent_android.cpp +953 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_WebBrowserComponent_linux.cpp +1659 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_WebBrowserComponent_mac.mm +1113 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_WebBrowserComponent_windows.cpp +1298 -0
- package/ios/juce_modules/juce_gui_extra/native/juce_XEmbedComponent_linux.cpp +739 -0
- package/package.json +1 -1
- package/ios/JuceModules.mm +0 -14
- package/ios/JuceToneGenerator.h +0 -39
- package/ios/JuceToneGenerator.mm +0 -613
|
@@ -0,0 +1,4036 @@
|
|
|
1
|
+
/*
|
|
2
|
+
==============================================================================
|
|
3
|
+
|
|
4
|
+
This file is part of the JUCE framework.
|
|
5
|
+
Copyright (c) Raw Material Software Limited
|
|
6
|
+
|
|
7
|
+
JUCE is an open source framework subject to commercial or open source
|
|
8
|
+
licensing.
|
|
9
|
+
|
|
10
|
+
By downloading, installing, or using the JUCE framework, or combining the
|
|
11
|
+
JUCE framework with any other source code, object code, content or any other
|
|
12
|
+
copyrightable work, you agree to the terms of the JUCE End User Licence
|
|
13
|
+
Agreement, and all incorporated terms including the JUCE Privacy Policy and
|
|
14
|
+
the JUCE Website Terms of Service, as applicable, which will bind you. If you
|
|
15
|
+
do not agree to the terms of these agreements, we will not license the JUCE
|
|
16
|
+
framework to you, and you must discontinue the installation or download
|
|
17
|
+
process and cease use of the JUCE framework.
|
|
18
|
+
|
|
19
|
+
JUCE End User Licence Agreement: https://juce.com/legal/juce-8-licence/
|
|
20
|
+
JUCE Privacy Policy: https://juce.com/juce-privacy-policy
|
|
21
|
+
JUCE Website Terms of Service: https://juce.com/juce-website-terms-of-service/
|
|
22
|
+
|
|
23
|
+
Or:
|
|
24
|
+
|
|
25
|
+
You may also use this code under the terms of the AGPLv3:
|
|
26
|
+
https://www.gnu.org/licenses/agpl-3.0.en.html
|
|
27
|
+
|
|
28
|
+
THE JUCE FRAMEWORK IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL
|
|
29
|
+
WARRANTIES, WHETHER EXPRESSED OR IMPLIED, INCLUDING WARRANTY OF
|
|
30
|
+
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, ARE DISCLAIMED.
|
|
31
|
+
|
|
32
|
+
==============================================================================
|
|
33
|
+
*/
|
|
34
|
+
|
|
35
|
+
namespace juce
|
|
36
|
+
{
|
|
37
|
+
|
|
38
|
+
#if JUCE_DEBUG && ! defined (JUCE_DEBUG_XERRORS)
|
|
39
|
+
#define JUCE_DEBUG_XERRORS 1
|
|
40
|
+
|
|
41
|
+
#if ! defined (JUCE_DEBUG_XERRORS_SYNCHRONOUSLY)
|
|
42
|
+
#define JUCE_DEBUG_XERRORS_SYNCHRONOUSLY 0
|
|
43
|
+
#endif
|
|
44
|
+
#endif
|
|
45
|
+
|
|
46
|
+
#if JUCE_MODULE_AVAILABLE_juce_gui_extra
|
|
47
|
+
#define JUCE_X11_SUPPORTS_XEMBED 1
|
|
48
|
+
#else
|
|
49
|
+
#define JUCE_X11_SUPPORTS_XEMBED 0
|
|
50
|
+
#endif
|
|
51
|
+
|
|
52
|
+
namespace
|
|
53
|
+
{
|
|
54
|
+
struct XFreeDeleter
|
|
55
|
+
{
|
|
56
|
+
void operator() (void* ptr) const
|
|
57
|
+
{
|
|
58
|
+
if (ptr != nullptr)
|
|
59
|
+
X11Symbols::getInstance()->xFree (ptr);
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
template <typename Data>
|
|
64
|
+
std::unique_ptr<Data, XFreeDeleter> makeXFreePtr (Data* raw) { return std::unique_ptr<Data, XFreeDeleter> (raw); }
|
|
65
|
+
|
|
66
|
+
template <typename Data, typename Deleter>
|
|
67
|
+
std::unique_ptr<Data, Deleter> makeDeletedPtr (Data* raw, const Deleter& d) { return std::unique_ptr<Data, Deleter> (raw, d); }
|
|
68
|
+
|
|
69
|
+
template <typename XValueType>
|
|
70
|
+
struct XValueHolder
|
|
71
|
+
{
|
|
72
|
+
XValueHolder (XValueType&& xv, const std::function<void(XValueType&)>& cleanup)
|
|
73
|
+
: value (std::move (xv)), cleanupFunc (cleanup)
|
|
74
|
+
{}
|
|
75
|
+
|
|
76
|
+
~XValueHolder()
|
|
77
|
+
{
|
|
78
|
+
cleanupFunc (value);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
XValueType value;
|
|
82
|
+
std::function<void(XValueType&)> cleanupFunc;
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
//==============================================================================
|
|
87
|
+
XWindowSystemUtilities::ScopedXLock::ScopedXLock()
|
|
88
|
+
{
|
|
89
|
+
if (auto* xWindow = XWindowSystem::getInstanceWithoutCreating())
|
|
90
|
+
if (auto* d = xWindow->getDisplay())
|
|
91
|
+
X11Symbols::getInstance()->xLockDisplay (d);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
XWindowSystemUtilities::ScopedXLock::~ScopedXLock()
|
|
95
|
+
{
|
|
96
|
+
if (auto* xWindow = XWindowSystem::getInstanceWithoutCreating())
|
|
97
|
+
if (auto* d = xWindow->getDisplay())
|
|
98
|
+
X11Symbols::getInstance()->xUnlockDisplay (d);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
//==============================================================================
|
|
102
|
+
XWindowSystemUtilities::Atoms::Atoms (::Display* display)
|
|
103
|
+
{
|
|
104
|
+
protocols = getIfExists (display, "WM_PROTOCOLS");
|
|
105
|
+
protocolList [TAKE_FOCUS] = getIfExists (display, "WM_TAKE_FOCUS");
|
|
106
|
+
protocolList [DELETE_WINDOW] = getIfExists (display, "WM_DELETE_WINDOW");
|
|
107
|
+
protocolList [PING] = getIfExists (display, "_NET_WM_PING");
|
|
108
|
+
changeState = getIfExists (display, "WM_CHANGE_STATE");
|
|
109
|
+
state = getIfExists (display, "WM_STATE");
|
|
110
|
+
userTime = getCreating (display, "_NET_WM_USER_TIME");
|
|
111
|
+
activeWin = getCreating (display, "_NET_ACTIVE_WINDOW");
|
|
112
|
+
pid = getCreating (display, "_NET_WM_PID");
|
|
113
|
+
windowType = getIfExists (display, "_NET_WM_WINDOW_TYPE");
|
|
114
|
+
windowState = getIfExists (display, "_NET_WM_STATE");
|
|
115
|
+
windowStateHidden = getIfExists (display, "_NET_WM_STATE_HIDDEN");
|
|
116
|
+
|
|
117
|
+
XdndAware = getCreating (display, "XdndAware");
|
|
118
|
+
XdndEnter = getCreating (display, "XdndEnter");
|
|
119
|
+
XdndLeave = getCreating (display, "XdndLeave");
|
|
120
|
+
XdndPosition = getCreating (display, "XdndPosition");
|
|
121
|
+
XdndStatus = getCreating (display, "XdndStatus");
|
|
122
|
+
XdndDrop = getCreating (display, "XdndDrop");
|
|
123
|
+
XdndFinished = getCreating (display, "XdndFinished");
|
|
124
|
+
XdndSelection = getCreating (display, "XdndSelection");
|
|
125
|
+
|
|
126
|
+
XdndTypeList = getCreating (display, "XdndTypeList");
|
|
127
|
+
XdndActionList = getCreating (display, "XdndActionList");
|
|
128
|
+
XdndActionCopy = getCreating (display, "XdndActionCopy");
|
|
129
|
+
XdndActionPrivate = getCreating (display, "XdndActionPrivate");
|
|
130
|
+
XdndActionDescription = getCreating (display, "XdndActionDescription");
|
|
131
|
+
|
|
132
|
+
XembedMsgType = getCreating (display, "_XEMBED");
|
|
133
|
+
XembedInfo = getCreating (display, "_XEMBED_INFO");
|
|
134
|
+
|
|
135
|
+
allowedMimeTypes[0] = getCreating (display, "UTF8_STRING");
|
|
136
|
+
allowedMimeTypes[1] = getCreating (display, "text/plain;charset=utf-8");
|
|
137
|
+
allowedMimeTypes[2] = getCreating (display, "text/plain");
|
|
138
|
+
allowedMimeTypes[3] = getCreating (display, "text/uri-list");
|
|
139
|
+
|
|
140
|
+
allowedActions[0] = getCreating (display, "XdndActionMove");
|
|
141
|
+
allowedActions[1] = XdndActionCopy;
|
|
142
|
+
allowedActions[2] = getCreating (display, "XdndActionLink");
|
|
143
|
+
allowedActions[3] = getCreating (display, "XdndActionAsk");
|
|
144
|
+
allowedActions[4] = XdndActionPrivate;
|
|
145
|
+
|
|
146
|
+
utf8String = getCreating (display, "UTF8_STRING");
|
|
147
|
+
clipboard = getCreating (display, "CLIPBOARD");
|
|
148
|
+
targets = getCreating (display, "TARGETS");
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
Atom XWindowSystemUtilities::Atoms::getIfExists (::Display* display, const char* name)
|
|
152
|
+
{
|
|
153
|
+
return X11Symbols::getInstance()->xInternAtom (display, name, True);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
Atom XWindowSystemUtilities::Atoms::getCreating (::Display* display, const char* name)
|
|
157
|
+
{
|
|
158
|
+
return X11Symbols::getInstance()->xInternAtom (display, name, False);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
String XWindowSystemUtilities::Atoms::getName (::Display* display, Atom atom)
|
|
162
|
+
{
|
|
163
|
+
if (atom == None)
|
|
164
|
+
return "None";
|
|
165
|
+
|
|
166
|
+
return makeXFreePtr (X11Symbols::getInstance()->xGetAtomName (display, atom)).get();
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
bool XWindowSystemUtilities::Atoms::isMimeTypeFile (::Display* display, Atom atom)
|
|
170
|
+
{
|
|
171
|
+
return getName (display, atom).equalsIgnoreCase ("text/uri-list");
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
//==============================================================================
|
|
175
|
+
XWindowSystemUtilities::GetXProperty::GetXProperty (::Display* display, Window window, Atom atom,
|
|
176
|
+
long offset, long length, bool shouldDelete, Atom requestedType)
|
|
177
|
+
{
|
|
178
|
+
success = (X11Symbols::getInstance()->xGetWindowProperty (display, window, atom, offset, length,
|
|
179
|
+
(Bool) shouldDelete, requestedType, &actualType,
|
|
180
|
+
&actualFormat, &numItems, &bytesLeft, &data) == Success)
|
|
181
|
+
&& data != nullptr;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
XWindowSystemUtilities::GetXProperty::~GetXProperty()
|
|
185
|
+
{
|
|
186
|
+
if (data != nullptr)
|
|
187
|
+
X11Symbols::getInstance()->xFree (data);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
//==============================================================================
|
|
191
|
+
std::unique_ptr<XWindowSystemUtilities::XSettings> XWindowSystemUtilities::XSettings::createXSettings (::Display* d)
|
|
192
|
+
{
|
|
193
|
+
const auto settingsAtom = Atoms::getCreating (d, "_XSETTINGS_SETTINGS");
|
|
194
|
+
const auto settingsWindow = X11Symbols::getInstance()->xGetSelectionOwner (d,
|
|
195
|
+
Atoms::getCreating (d, "_XSETTINGS_S0"));
|
|
196
|
+
|
|
197
|
+
if (settingsWindow == None)
|
|
198
|
+
return {};
|
|
199
|
+
|
|
200
|
+
return rawToUniquePtr (new XWindowSystemUtilities::XSettings (d, settingsWindow, settingsAtom));
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
XWindowSystemUtilities::XSettings::XSettings (::Display* d, ::Window settingsWindowIn, Atom settingsAtomIn)
|
|
204
|
+
: display (d), settingsWindow (settingsWindowIn), settingsAtom (settingsAtomIn)
|
|
205
|
+
{
|
|
206
|
+
update();
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
XWindowSystemUtilities::XSetting XWindowSystemUtilities::XSettings::getSetting (const String& name) const
|
|
210
|
+
{
|
|
211
|
+
const auto iter = settings.find (name);
|
|
212
|
+
|
|
213
|
+
if (iter != settings.end())
|
|
214
|
+
return iter->second;
|
|
215
|
+
|
|
216
|
+
return {};
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
void XWindowSystemUtilities::XSettings::update()
|
|
220
|
+
{
|
|
221
|
+
const GetXProperty prop { display,
|
|
222
|
+
settingsWindow,
|
|
223
|
+
settingsAtom,
|
|
224
|
+
0L,
|
|
225
|
+
std::numeric_limits<long>::max(),
|
|
226
|
+
false,
|
|
227
|
+
settingsAtom };
|
|
228
|
+
|
|
229
|
+
if (prop.success
|
|
230
|
+
&& prop.actualType == settingsAtom
|
|
231
|
+
&& prop.actualFormat == 8
|
|
232
|
+
&& prop.numItems > 0)
|
|
233
|
+
{
|
|
234
|
+
const auto bytes = (size_t) prop.numItems;
|
|
235
|
+
auto* data = prop.data;
|
|
236
|
+
size_t byteNum = 0;
|
|
237
|
+
|
|
238
|
+
const auto increment = [&] (size_t amount)
|
|
239
|
+
{
|
|
240
|
+
data += amount;
|
|
241
|
+
byteNum += amount;
|
|
242
|
+
};
|
|
243
|
+
|
|
244
|
+
struct Header
|
|
245
|
+
{
|
|
246
|
+
CARD8 byteOrder;
|
|
247
|
+
CARD8 padding[3];
|
|
248
|
+
CARD32 serial;
|
|
249
|
+
CARD32 nSettings;
|
|
250
|
+
};
|
|
251
|
+
|
|
252
|
+
const auto* header = unalignedPointerCast<const Header*> (data);
|
|
253
|
+
const auto headerSerial = (int) header->serial;
|
|
254
|
+
increment (sizeof (Header));
|
|
255
|
+
|
|
256
|
+
const auto readCARD16 = [&]() -> CARD16
|
|
257
|
+
{
|
|
258
|
+
if (byteNum + sizeof (CARD16) > bytes)
|
|
259
|
+
return {};
|
|
260
|
+
|
|
261
|
+
const auto value = header->byteOrder == MSBFirst ? ByteOrder::bigEndianShort (data)
|
|
262
|
+
: ByteOrder::littleEndianShort (data);
|
|
263
|
+
increment (sizeof (CARD16));
|
|
264
|
+
return value;
|
|
265
|
+
};
|
|
266
|
+
|
|
267
|
+
const auto readCARD32 = [&]() -> CARD32
|
|
268
|
+
{
|
|
269
|
+
if (byteNum + sizeof (CARD32) > bytes)
|
|
270
|
+
return {};
|
|
271
|
+
|
|
272
|
+
const auto value = header->byteOrder == MSBFirst ? ByteOrder::bigEndianInt (data)
|
|
273
|
+
: ByteOrder::littleEndianInt (data);
|
|
274
|
+
increment (sizeof (CARD32));
|
|
275
|
+
return value;
|
|
276
|
+
};
|
|
277
|
+
|
|
278
|
+
const auto readString = [&] (size_t nameLen) -> String
|
|
279
|
+
{
|
|
280
|
+
const auto padded = (nameLen + 3) & (~(size_t) 3);
|
|
281
|
+
|
|
282
|
+
if (byteNum + padded > bytes)
|
|
283
|
+
return {};
|
|
284
|
+
|
|
285
|
+
auto* ptr = reinterpret_cast<const char*> (data);
|
|
286
|
+
const String result (ptr, nameLen);
|
|
287
|
+
increment (padded);
|
|
288
|
+
return result;
|
|
289
|
+
};
|
|
290
|
+
|
|
291
|
+
CARD16 setting = 0;
|
|
292
|
+
|
|
293
|
+
while (byteNum < bytes && setting < header->nSettings)
|
|
294
|
+
{
|
|
295
|
+
const auto type = *reinterpret_cast<const char*> (data);
|
|
296
|
+
increment (2);
|
|
297
|
+
|
|
298
|
+
const auto name = readString (readCARD16());
|
|
299
|
+
const auto serial = (int) readCARD32();
|
|
300
|
+
|
|
301
|
+
enum { XSettingsTypeInteger, XSettingsTypeString, XSettingsTypeColor };
|
|
302
|
+
|
|
303
|
+
const auto parsedSetting = [&]() -> XSetting
|
|
304
|
+
{
|
|
305
|
+
switch (type)
|
|
306
|
+
{
|
|
307
|
+
case XSettingsTypeInteger:
|
|
308
|
+
return { name, (int) readCARD32() };
|
|
309
|
+
|
|
310
|
+
case XSettingsTypeString:
|
|
311
|
+
return { name, readString (readCARD32()) };
|
|
312
|
+
|
|
313
|
+
case XSettingsTypeColor:
|
|
314
|
+
// Order is important, these should be kept as separate statements!
|
|
315
|
+
const auto r = (uint8) readCARD16();
|
|
316
|
+
const auto g = (uint8) readCARD16();
|
|
317
|
+
const auto b = (uint8) readCARD16();
|
|
318
|
+
const auto a = (uint8) readCARD16();
|
|
319
|
+
return { name, Colour { r, g, b, a } };
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
return {};
|
|
323
|
+
}();
|
|
324
|
+
|
|
325
|
+
if (serial > lastUpdateSerial)
|
|
326
|
+
{
|
|
327
|
+
settings[parsedSetting.name] = parsedSetting;
|
|
328
|
+
listeners.call ([&parsedSetting] (Listener& l) { l.settingChanged (parsedSetting); });
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
setting += 1;
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
lastUpdateSerial = headerSerial;
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
//==============================================================================
|
|
339
|
+
::Window juce_messageWindowHandle;
|
|
340
|
+
XContext windowHandleXContext;
|
|
341
|
+
|
|
342
|
+
#if JUCE_X11_SUPPORTS_XEMBED
|
|
343
|
+
bool juce_handleXEmbedEvent (ComponentPeer*, void*);
|
|
344
|
+
unsigned long juce_getCurrentFocusWindow (ComponentPeer*);
|
|
345
|
+
#endif
|
|
346
|
+
|
|
347
|
+
struct MotifWmHints
|
|
348
|
+
{
|
|
349
|
+
unsigned long flags = 0;
|
|
350
|
+
unsigned long functions = 0;
|
|
351
|
+
unsigned long decorations = 0;
|
|
352
|
+
long input_mode = 0;
|
|
353
|
+
unsigned long status = 0;
|
|
354
|
+
};
|
|
355
|
+
|
|
356
|
+
//=============================== X11 - Error Handling =========================
|
|
357
|
+
namespace X11ErrorHandling
|
|
358
|
+
{
|
|
359
|
+
static XErrorHandler oldErrorHandler = {};
|
|
360
|
+
static XIOErrorHandler oldIOErrorHandler = {};
|
|
361
|
+
|
|
362
|
+
// Usually happens when client-server connection is broken
|
|
363
|
+
static int ioErrorHandler (::Display*)
|
|
364
|
+
{
|
|
365
|
+
DBG ("ERROR: connection to X server broken.. terminating.");
|
|
366
|
+
|
|
367
|
+
if (JUCEApplicationBase::isStandaloneApp())
|
|
368
|
+
MessageManager::getInstance()->stopDispatchLoop();
|
|
369
|
+
|
|
370
|
+
return 0;
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
static int errorHandler ([[maybe_unused]] ::Display* display, [[maybe_unused]] XErrorEvent* event)
|
|
374
|
+
{
|
|
375
|
+
#if JUCE_DEBUG_XERRORS
|
|
376
|
+
char errorStr[64] = { 0 };
|
|
377
|
+
char requestStr[64] = { 0 };
|
|
378
|
+
|
|
379
|
+
X11Symbols::getInstance()->xGetErrorText (display, event->error_code, errorStr, 64);
|
|
380
|
+
X11Symbols::getInstance()->xGetErrorDatabaseText (display, "XRequest", String (event->request_code).toUTF8(), "Unknown", requestStr, 64);
|
|
381
|
+
|
|
382
|
+
DBG ("ERROR: X returned " << errorStr << " for operation " << requestStr);
|
|
383
|
+
#endif
|
|
384
|
+
|
|
385
|
+
return 0;
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
static void installXErrorHandlers()
|
|
389
|
+
{
|
|
390
|
+
oldIOErrorHandler = X11Symbols::getInstance()->xSetIOErrorHandler (ioErrorHandler);
|
|
391
|
+
oldErrorHandler = X11Symbols::getInstance()->xSetErrorHandler (errorHandler);
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
static void removeXErrorHandlers()
|
|
395
|
+
{
|
|
396
|
+
X11Symbols::getInstance()->xSetIOErrorHandler (oldIOErrorHandler);
|
|
397
|
+
oldIOErrorHandler = {};
|
|
398
|
+
|
|
399
|
+
X11Symbols::getInstance()->xSetErrorHandler (oldErrorHandler);
|
|
400
|
+
oldErrorHandler = {};
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
//=============================== X11 - Keys ===================================
|
|
405
|
+
namespace Keys
|
|
406
|
+
{
|
|
407
|
+
enum MouseButtons
|
|
408
|
+
{
|
|
409
|
+
NoButton = 0,
|
|
410
|
+
LeftButton = 1,
|
|
411
|
+
MiddleButton = 2,
|
|
412
|
+
RightButton = 3,
|
|
413
|
+
WheelUp = 4,
|
|
414
|
+
WheelDown = 5
|
|
415
|
+
};
|
|
416
|
+
|
|
417
|
+
static int AltMask = 0;
|
|
418
|
+
static int NumLockMask = 0;
|
|
419
|
+
static bool numLock = false;
|
|
420
|
+
static bool capsLock = false;
|
|
421
|
+
static char keyStates [32];
|
|
422
|
+
static constexpr int extendedKeyModifier = 0x10000000;
|
|
423
|
+
static bool modifierKeysAreStale = false;
|
|
424
|
+
|
|
425
|
+
static void refreshStaleModifierKeys()
|
|
426
|
+
{
|
|
427
|
+
if (modifierKeysAreStale)
|
|
428
|
+
{
|
|
429
|
+
XWindowSystem::getInstance()->getNativeRealtimeModifiers();
|
|
430
|
+
modifierKeysAreStale = false;
|
|
431
|
+
}
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
// Call this function when only the mouse keys need to be refreshed e.g. when the event
|
|
435
|
+
// parameter already has information about the keys.
|
|
436
|
+
static void refreshStaleMouseKeys()
|
|
437
|
+
{
|
|
438
|
+
if (modifierKeysAreStale)
|
|
439
|
+
{
|
|
440
|
+
const auto oldMods = ModifierKeys::currentModifiers;
|
|
441
|
+
XWindowSystem::getInstance()->getNativeRealtimeModifiers();
|
|
442
|
+
ModifierKeys::currentModifiers = oldMods.withoutMouseButtons()
|
|
443
|
+
.withFlags (ModifierKeys::currentModifiers.withOnlyMouseButtons()
|
|
444
|
+
.getRawFlags());
|
|
445
|
+
modifierKeysAreStale = false;
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
const int KeyPress::spaceKey = XK_space & 0xff;
|
|
451
|
+
const int KeyPress::returnKey = XK_Return & 0xff;
|
|
452
|
+
const int KeyPress::escapeKey = XK_Escape & 0xff;
|
|
453
|
+
const int KeyPress::backspaceKey = XK_BackSpace & 0xff;
|
|
454
|
+
const int KeyPress::leftKey = (XK_Left & 0xff) | Keys::extendedKeyModifier;
|
|
455
|
+
const int KeyPress::rightKey = (XK_Right & 0xff) | Keys::extendedKeyModifier;
|
|
456
|
+
const int KeyPress::upKey = (XK_Up & 0xff) | Keys::extendedKeyModifier;
|
|
457
|
+
const int KeyPress::downKey = (XK_Down & 0xff) | Keys::extendedKeyModifier;
|
|
458
|
+
const int KeyPress::pageUpKey = (XK_Page_Up & 0xff) | Keys::extendedKeyModifier;
|
|
459
|
+
const int KeyPress::pageDownKey = (XK_Page_Down & 0xff) | Keys::extendedKeyModifier;
|
|
460
|
+
const int KeyPress::endKey = (XK_End & 0xff) | Keys::extendedKeyModifier;
|
|
461
|
+
const int KeyPress::homeKey = (XK_Home & 0xff) | Keys::extendedKeyModifier;
|
|
462
|
+
const int KeyPress::insertKey = (XK_Insert & 0xff) | Keys::extendedKeyModifier;
|
|
463
|
+
const int KeyPress::deleteKey = (XK_Delete & 0xff) | Keys::extendedKeyModifier;
|
|
464
|
+
const int KeyPress::tabKey = XK_Tab & 0xff;
|
|
465
|
+
const int KeyPress::F1Key = (XK_F1 & 0xff) | Keys::extendedKeyModifier;
|
|
466
|
+
const int KeyPress::F2Key = (XK_F2 & 0xff) | Keys::extendedKeyModifier;
|
|
467
|
+
const int KeyPress::F3Key = (XK_F3 & 0xff) | Keys::extendedKeyModifier;
|
|
468
|
+
const int KeyPress::F4Key = (XK_F4 & 0xff) | Keys::extendedKeyModifier;
|
|
469
|
+
const int KeyPress::F5Key = (XK_F5 & 0xff) | Keys::extendedKeyModifier;
|
|
470
|
+
const int KeyPress::F6Key = (XK_F6 & 0xff) | Keys::extendedKeyModifier;
|
|
471
|
+
const int KeyPress::F7Key = (XK_F7 & 0xff) | Keys::extendedKeyModifier;
|
|
472
|
+
const int KeyPress::F8Key = (XK_F8 & 0xff) | Keys::extendedKeyModifier;
|
|
473
|
+
const int KeyPress::F9Key = (XK_F9 & 0xff) | Keys::extendedKeyModifier;
|
|
474
|
+
const int KeyPress::F10Key = (XK_F10 & 0xff) | Keys::extendedKeyModifier;
|
|
475
|
+
const int KeyPress::F11Key = (XK_F11 & 0xff) | Keys::extendedKeyModifier;
|
|
476
|
+
const int KeyPress::F12Key = (XK_F12 & 0xff) | Keys::extendedKeyModifier;
|
|
477
|
+
const int KeyPress::F13Key = (XK_F13 & 0xff) | Keys::extendedKeyModifier;
|
|
478
|
+
const int KeyPress::F14Key = (XK_F14 & 0xff) | Keys::extendedKeyModifier;
|
|
479
|
+
const int KeyPress::F15Key = (XK_F15 & 0xff) | Keys::extendedKeyModifier;
|
|
480
|
+
const int KeyPress::F16Key = (XK_F16 & 0xff) | Keys::extendedKeyModifier;
|
|
481
|
+
const int KeyPress::F17Key = (XK_F17 & 0xff) | Keys::extendedKeyModifier;
|
|
482
|
+
const int KeyPress::F18Key = (XK_F18 & 0xff) | Keys::extendedKeyModifier;
|
|
483
|
+
const int KeyPress::F19Key = (XK_F19 & 0xff) | Keys::extendedKeyModifier;
|
|
484
|
+
const int KeyPress::F20Key = (XK_F20 & 0xff) | Keys::extendedKeyModifier;
|
|
485
|
+
const int KeyPress::F21Key = (XK_F21 & 0xff) | Keys::extendedKeyModifier;
|
|
486
|
+
const int KeyPress::F22Key = (XK_F22 & 0xff) | Keys::extendedKeyModifier;
|
|
487
|
+
const int KeyPress::F23Key = (XK_F23 & 0xff) | Keys::extendedKeyModifier;
|
|
488
|
+
const int KeyPress::F24Key = (XK_F24 & 0xff) | Keys::extendedKeyModifier;
|
|
489
|
+
const int KeyPress::F25Key = (XK_F25 & 0xff) | Keys::extendedKeyModifier;
|
|
490
|
+
const int KeyPress::F26Key = (XK_F26 & 0xff) | Keys::extendedKeyModifier;
|
|
491
|
+
const int KeyPress::F27Key = (XK_F27 & 0xff) | Keys::extendedKeyModifier;
|
|
492
|
+
const int KeyPress::F28Key = (XK_F28 & 0xff) | Keys::extendedKeyModifier;
|
|
493
|
+
const int KeyPress::F29Key = (XK_F29 & 0xff) | Keys::extendedKeyModifier;
|
|
494
|
+
const int KeyPress::F30Key = (XK_F30 & 0xff) | Keys::extendedKeyModifier;
|
|
495
|
+
const int KeyPress::F31Key = (XK_F31 & 0xff) | Keys::extendedKeyModifier;
|
|
496
|
+
const int KeyPress::F32Key = (XK_F32 & 0xff) | Keys::extendedKeyModifier;
|
|
497
|
+
const int KeyPress::F33Key = (XK_F33 & 0xff) | Keys::extendedKeyModifier;
|
|
498
|
+
const int KeyPress::F34Key = (XK_F34 & 0xff) | Keys::extendedKeyModifier;
|
|
499
|
+
const int KeyPress::F35Key = (XK_F35 & 0xff) | Keys::extendedKeyModifier;
|
|
500
|
+
const int KeyPress::numberPad0 = (XK_KP_0 & 0xff) | Keys::extendedKeyModifier;
|
|
501
|
+
const int KeyPress::numberPad1 = (XK_KP_1 & 0xff) | Keys::extendedKeyModifier;
|
|
502
|
+
const int KeyPress::numberPad2 = (XK_KP_2 & 0xff) | Keys::extendedKeyModifier;
|
|
503
|
+
const int KeyPress::numberPad3 = (XK_KP_3 & 0xff) | Keys::extendedKeyModifier;
|
|
504
|
+
const int KeyPress::numberPad4 = (XK_KP_4 & 0xff) | Keys::extendedKeyModifier;
|
|
505
|
+
const int KeyPress::numberPad5 = (XK_KP_5 & 0xff) | Keys::extendedKeyModifier;
|
|
506
|
+
const int KeyPress::numberPad6 = (XK_KP_6 & 0xff) | Keys::extendedKeyModifier;
|
|
507
|
+
const int KeyPress::numberPad7 = (XK_KP_7 & 0xff) | Keys::extendedKeyModifier;
|
|
508
|
+
const int KeyPress::numberPad8 = (XK_KP_8 & 0xff) | Keys::extendedKeyModifier;
|
|
509
|
+
const int KeyPress::numberPad9 = (XK_KP_9 & 0xff) | Keys::extendedKeyModifier;
|
|
510
|
+
const int KeyPress::numberPadAdd = (XK_KP_Add & 0xff) | Keys::extendedKeyModifier;
|
|
511
|
+
const int KeyPress::numberPadSubtract = (XK_KP_Subtract & 0xff) | Keys::extendedKeyModifier;
|
|
512
|
+
const int KeyPress::numberPadMultiply = (XK_KP_Multiply & 0xff) | Keys::extendedKeyModifier;
|
|
513
|
+
const int KeyPress::numberPadDivide = (XK_KP_Divide & 0xff) | Keys::extendedKeyModifier;
|
|
514
|
+
const int KeyPress::numberPadSeparator = (XK_KP_Separator & 0xff) | Keys::extendedKeyModifier;
|
|
515
|
+
const int KeyPress::numberPadDecimalPoint = (XK_KP_Decimal & 0xff) | Keys::extendedKeyModifier;
|
|
516
|
+
const int KeyPress::numberPadEquals = (XK_KP_Equal & 0xff) | Keys::extendedKeyModifier;
|
|
517
|
+
const int KeyPress::numberPadDelete = (XK_KP_Delete & 0xff) | Keys::extendedKeyModifier;
|
|
518
|
+
const int KeyPress::playKey = ((int) 0xffeeff00) | Keys::extendedKeyModifier;
|
|
519
|
+
const int KeyPress::stopKey = ((int) 0xffeeff01) | Keys::extendedKeyModifier;
|
|
520
|
+
const int KeyPress::fastForwardKey = ((int) 0xffeeff02) | Keys::extendedKeyModifier;
|
|
521
|
+
const int KeyPress::rewindKey = ((int) 0xffeeff03) | Keys::extendedKeyModifier;
|
|
522
|
+
|
|
523
|
+
static void updateKeyStates (int keycode, bool press) noexcept
|
|
524
|
+
{
|
|
525
|
+
auto keybyte = keycode >> 3;
|
|
526
|
+
auto keybit = (1 << (keycode & 7));
|
|
527
|
+
|
|
528
|
+
if (press)
|
|
529
|
+
Keys::keyStates [keybyte] |= keybit;
|
|
530
|
+
else
|
|
531
|
+
Keys::keyStates [keybyte] &= ~keybit;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
static void updateKeyModifiers (int status) noexcept
|
|
535
|
+
{
|
|
536
|
+
int keyMods = 0;
|
|
537
|
+
|
|
538
|
+
if ((status & ShiftMask) != 0) keyMods |= ModifierKeys::shiftModifier;
|
|
539
|
+
if ((status & ControlMask) != 0) keyMods |= ModifierKeys::ctrlModifier;
|
|
540
|
+
if ((status & Keys::AltMask) != 0) keyMods |= ModifierKeys::altModifier;
|
|
541
|
+
|
|
542
|
+
ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withOnlyMouseButtons().withFlags (keyMods);
|
|
543
|
+
|
|
544
|
+
Keys::numLock = ((status & Keys::NumLockMask) != 0);
|
|
545
|
+
Keys::capsLock = ((status & LockMask) != 0);
|
|
546
|
+
}
|
|
547
|
+
|
|
548
|
+
static bool updateKeyModifiersFromSym (KeySym sym, bool press) noexcept
|
|
549
|
+
{
|
|
550
|
+
int modifier = 0;
|
|
551
|
+
bool isModifier = true;
|
|
552
|
+
|
|
553
|
+
switch (sym)
|
|
554
|
+
{
|
|
555
|
+
case XK_Shift_L:
|
|
556
|
+
case XK_Shift_R: modifier = ModifierKeys::shiftModifier; break;
|
|
557
|
+
|
|
558
|
+
case XK_Control_L:
|
|
559
|
+
case XK_Control_R: modifier = ModifierKeys::ctrlModifier; break;
|
|
560
|
+
|
|
561
|
+
case XK_Alt_L:
|
|
562
|
+
case XK_Alt_R: modifier = ModifierKeys::altModifier; break;
|
|
563
|
+
|
|
564
|
+
case XK_Num_Lock:
|
|
565
|
+
if (press)
|
|
566
|
+
Keys::numLock = ! Keys::numLock;
|
|
567
|
+
|
|
568
|
+
break;
|
|
569
|
+
|
|
570
|
+
case XK_Caps_Lock:
|
|
571
|
+
if (press)
|
|
572
|
+
Keys::capsLock = ! Keys::capsLock;
|
|
573
|
+
|
|
574
|
+
break;
|
|
575
|
+
|
|
576
|
+
case XK_Scroll_Lock:
|
|
577
|
+
break;
|
|
578
|
+
|
|
579
|
+
default:
|
|
580
|
+
isModifier = false;
|
|
581
|
+
break;
|
|
582
|
+
}
|
|
583
|
+
|
|
584
|
+
ModifierKeys::currentModifiers = press ? ModifierKeys::currentModifiers.withFlags (modifier)
|
|
585
|
+
: ModifierKeys::currentModifiers.withoutFlags (modifier);
|
|
586
|
+
|
|
587
|
+
return isModifier;
|
|
588
|
+
}
|
|
589
|
+
|
|
590
|
+
enum
|
|
591
|
+
{
|
|
592
|
+
KeyPressEventType = 2
|
|
593
|
+
};
|
|
594
|
+
|
|
595
|
+
//================================== X11 - Shm =================================
|
|
596
|
+
#if JUCE_USE_XSHM
|
|
597
|
+
namespace XSHMHelpers
|
|
598
|
+
{
|
|
599
|
+
static int trappedErrorCode = 0;
|
|
600
|
+
|
|
601
|
+
extern "C" int errorTrapHandler (Display*, XErrorEvent* err);
|
|
602
|
+
extern "C" int errorTrapHandler (Display*, XErrorEvent* err)
|
|
603
|
+
{
|
|
604
|
+
trappedErrorCode = err->error_code;
|
|
605
|
+
return 0;
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
static bool isShmAvailable (::Display* display)
|
|
609
|
+
{
|
|
610
|
+
static bool isChecked = false;
|
|
611
|
+
static bool isAvailable = false;
|
|
612
|
+
|
|
613
|
+
if (! isChecked)
|
|
614
|
+
{
|
|
615
|
+
isChecked = true;
|
|
616
|
+
|
|
617
|
+
if (display != nullptr)
|
|
618
|
+
{
|
|
619
|
+
int major, minor;
|
|
620
|
+
Bool pixmaps;
|
|
621
|
+
|
|
622
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
623
|
+
|
|
624
|
+
if (X11Symbols::getInstance()->xShmQueryVersion (display, &major, &minor, &pixmaps))
|
|
625
|
+
{
|
|
626
|
+
trappedErrorCode = 0;
|
|
627
|
+
auto oldHandler = X11Symbols::getInstance()->xSetErrorHandler (errorTrapHandler);
|
|
628
|
+
|
|
629
|
+
XShmSegmentInfo segmentInfo;
|
|
630
|
+
zerostruct (segmentInfo);
|
|
631
|
+
|
|
632
|
+
if (auto* xImage = X11Symbols::getInstance()->xShmCreateImage (display,
|
|
633
|
+
X11Symbols::getInstance()->xDefaultVisual (display, X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
634
|
+
24, ZPixmap, nullptr, &segmentInfo, 50, 50))
|
|
635
|
+
{
|
|
636
|
+
if ((segmentInfo.shmid = shmget (IPC_PRIVATE,
|
|
637
|
+
(size_t) (xImage->bytes_per_line * xImage->height),
|
|
638
|
+
IPC_CREAT | 0777)) >= 0)
|
|
639
|
+
{
|
|
640
|
+
segmentInfo.shmaddr = (char*) shmat (segmentInfo.shmid, nullptr, 0);
|
|
641
|
+
|
|
642
|
+
if (segmentInfo.shmaddr != (void*) -1)
|
|
643
|
+
{
|
|
644
|
+
segmentInfo.readOnly = False;
|
|
645
|
+
xImage->data = segmentInfo.shmaddr;
|
|
646
|
+
X11Symbols::getInstance()->xSync (display, False);
|
|
647
|
+
|
|
648
|
+
if (X11Symbols::getInstance()->xShmAttach (display, &segmentInfo) != 0)
|
|
649
|
+
{
|
|
650
|
+
X11Symbols::getInstance()->xShmDetach (display, &segmentInfo);
|
|
651
|
+
X11Symbols::getInstance()->xSync (display, False);
|
|
652
|
+
|
|
653
|
+
isAvailable = true;
|
|
654
|
+
}
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
X11Symbols::getInstance()->xFlush (display);
|
|
658
|
+
X11Symbols::getInstance()->xDestroyImage (xImage);
|
|
659
|
+
|
|
660
|
+
shmdt (segmentInfo.shmaddr);
|
|
661
|
+
}
|
|
662
|
+
|
|
663
|
+
shmctl (segmentInfo.shmid, IPC_RMID, nullptr);
|
|
664
|
+
|
|
665
|
+
X11Symbols::getInstance()->xSetErrorHandler (oldHandler);
|
|
666
|
+
|
|
667
|
+
if (trappedErrorCode != 0)
|
|
668
|
+
isAvailable = false;
|
|
669
|
+
}
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
}
|
|
673
|
+
|
|
674
|
+
return isAvailable;
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
#endif
|
|
678
|
+
|
|
679
|
+
//=============================== X11 - Render =================================
|
|
680
|
+
#if JUCE_USE_XRENDER
|
|
681
|
+
namespace XRender
|
|
682
|
+
{
|
|
683
|
+
static bool isAvailable (::Display* display)
|
|
684
|
+
{
|
|
685
|
+
int major, minor;
|
|
686
|
+
return X11Symbols::getInstance()->xRenderQueryVersion (display, &major, &minor);
|
|
687
|
+
}
|
|
688
|
+
|
|
689
|
+
static bool hasCompositingWindowManager (::Display* display)
|
|
690
|
+
{
|
|
691
|
+
return display != nullptr
|
|
692
|
+
&& X11Symbols::getInstance()->xGetSelectionOwner (display,
|
|
693
|
+
XWindowSystemUtilities::Atoms::getCreating (display, "_NET_WM_CM_S0")) != 0;
|
|
694
|
+
}
|
|
695
|
+
|
|
696
|
+
static XRenderPictFormat* findPictureFormat (::Display* display)
|
|
697
|
+
{
|
|
698
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
699
|
+
|
|
700
|
+
if (isAvailable (display))
|
|
701
|
+
{
|
|
702
|
+
if (auto* pictFormat = X11Symbols::getInstance()->xRenderFindStandardFormat (display, PictStandardARGB32))
|
|
703
|
+
{
|
|
704
|
+
XRenderPictFormat desiredFormat;
|
|
705
|
+
desiredFormat.type = PictTypeDirect;
|
|
706
|
+
desiredFormat.depth = 32;
|
|
707
|
+
|
|
708
|
+
desiredFormat.direct.alphaMask = 0xff;
|
|
709
|
+
desiredFormat.direct.redMask = 0xff;
|
|
710
|
+
desiredFormat.direct.greenMask = 0xff;
|
|
711
|
+
desiredFormat.direct.blueMask = 0xff;
|
|
712
|
+
|
|
713
|
+
desiredFormat.direct.alpha = 24;
|
|
714
|
+
desiredFormat.direct.red = 16;
|
|
715
|
+
desiredFormat.direct.green = 8;
|
|
716
|
+
desiredFormat.direct.blue = 0;
|
|
717
|
+
|
|
718
|
+
pictFormat = X11Symbols::getInstance()->xRenderFindFormat (display,
|
|
719
|
+
PictFormatType | PictFormatDepth
|
|
720
|
+
| PictFormatRedMask | PictFormatRed
|
|
721
|
+
| PictFormatGreenMask | PictFormatGreen
|
|
722
|
+
| PictFormatBlueMask | PictFormatBlue
|
|
723
|
+
| PictFormatAlphaMask | PictFormatAlpha,
|
|
724
|
+
&desiredFormat,
|
|
725
|
+
0);
|
|
726
|
+
|
|
727
|
+
return pictFormat;
|
|
728
|
+
}
|
|
729
|
+
}
|
|
730
|
+
|
|
731
|
+
return nullptr;
|
|
732
|
+
}
|
|
733
|
+
}
|
|
734
|
+
#endif
|
|
735
|
+
|
|
736
|
+
//================================ X11 - Visuals ===============================
|
|
737
|
+
namespace Visuals
|
|
738
|
+
{
|
|
739
|
+
static Visual* findVisualWithDepth (::Display* display, int desiredDepth)
|
|
740
|
+
{
|
|
741
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
742
|
+
|
|
743
|
+
Visual* visual = nullptr;
|
|
744
|
+
int numVisuals = 0;
|
|
745
|
+
auto desiredMask = VisualNoMask;
|
|
746
|
+
XVisualInfo desiredVisual;
|
|
747
|
+
|
|
748
|
+
desiredVisual.screen = X11Symbols::getInstance()->xDefaultScreen (display);
|
|
749
|
+
desiredVisual.depth = desiredDepth;
|
|
750
|
+
|
|
751
|
+
desiredMask = VisualScreenMask | VisualDepthMask;
|
|
752
|
+
|
|
753
|
+
if (desiredDepth == 32)
|
|
754
|
+
{
|
|
755
|
+
desiredVisual.c_class = TrueColor;
|
|
756
|
+
desiredVisual.red_mask = 0x00FF0000;
|
|
757
|
+
desiredVisual.green_mask = 0x0000FF00;
|
|
758
|
+
desiredVisual.blue_mask = 0x000000FF;
|
|
759
|
+
desiredVisual.bits_per_rgb = 8;
|
|
760
|
+
|
|
761
|
+
desiredMask |= VisualClassMask;
|
|
762
|
+
desiredMask |= VisualRedMaskMask;
|
|
763
|
+
desiredMask |= VisualGreenMaskMask;
|
|
764
|
+
desiredMask |= VisualBlueMaskMask;
|
|
765
|
+
desiredMask |= VisualBitsPerRGBMask;
|
|
766
|
+
}
|
|
767
|
+
|
|
768
|
+
if (auto xvinfos = makeXFreePtr (X11Symbols::getInstance()->xGetVisualInfo (display, desiredMask, &desiredVisual, &numVisuals)))
|
|
769
|
+
{
|
|
770
|
+
for (int i = 0; i < numVisuals; i++)
|
|
771
|
+
{
|
|
772
|
+
if (xvinfos.get()[i].depth == desiredDepth)
|
|
773
|
+
{
|
|
774
|
+
visual = xvinfos.get()[i].visual;
|
|
775
|
+
break;
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
}
|
|
779
|
+
|
|
780
|
+
return visual;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
static Visual* findVisualFormat (::Display* display, int desiredDepth, int& matchedDepth)
|
|
784
|
+
{
|
|
785
|
+
Visual* visual = nullptr;
|
|
786
|
+
|
|
787
|
+
if (desiredDepth == 32)
|
|
788
|
+
{
|
|
789
|
+
#if JUCE_USE_XSHM
|
|
790
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
791
|
+
{
|
|
792
|
+
#if JUCE_USE_XRENDER
|
|
793
|
+
if (XRender::isAvailable (display))
|
|
794
|
+
{
|
|
795
|
+
if (XRender::findPictureFormat (display) != nullptr)
|
|
796
|
+
{
|
|
797
|
+
int numVisuals = 0;
|
|
798
|
+
XVisualInfo desiredVisual;
|
|
799
|
+
desiredVisual.screen = X11Symbols::getInstance()->xDefaultScreen (display);
|
|
800
|
+
desiredVisual.depth = 32;
|
|
801
|
+
desiredVisual.bits_per_rgb = 8;
|
|
802
|
+
|
|
803
|
+
if (auto xvinfos = makeXFreePtr (X11Symbols::getInstance()->xGetVisualInfo (display,
|
|
804
|
+
VisualScreenMask | VisualDepthMask | VisualBitsPerRGBMask,
|
|
805
|
+
&desiredVisual, &numVisuals)))
|
|
806
|
+
{
|
|
807
|
+
for (int i = 0; i < numVisuals; ++i)
|
|
808
|
+
{
|
|
809
|
+
auto pictVisualFormat = X11Symbols::getInstance()->xRenderFindVisualFormat (display, xvinfos.get()[i].visual);
|
|
810
|
+
|
|
811
|
+
if (pictVisualFormat != nullptr
|
|
812
|
+
&& pictVisualFormat->type == PictTypeDirect
|
|
813
|
+
&& pictVisualFormat->direct.alphaMask)
|
|
814
|
+
{
|
|
815
|
+
visual = xvinfos.get()[i].visual;
|
|
816
|
+
matchedDepth = 32;
|
|
817
|
+
break;
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
}
|
|
822
|
+
}
|
|
823
|
+
#endif
|
|
824
|
+
if (visual == nullptr)
|
|
825
|
+
{
|
|
826
|
+
visual = findVisualWithDepth (display, 32);
|
|
827
|
+
|
|
828
|
+
if (visual != nullptr)
|
|
829
|
+
matchedDepth = 32;
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
#endif
|
|
833
|
+
}
|
|
834
|
+
|
|
835
|
+
if (visual == nullptr && desiredDepth >= 24)
|
|
836
|
+
{
|
|
837
|
+
visual = findVisualWithDepth (display, 24);
|
|
838
|
+
|
|
839
|
+
if (visual != nullptr)
|
|
840
|
+
matchedDepth = 24;
|
|
841
|
+
}
|
|
842
|
+
|
|
843
|
+
if (visual == nullptr && desiredDepth >= 16)
|
|
844
|
+
{
|
|
845
|
+
visual = findVisualWithDepth (display, 16);
|
|
846
|
+
|
|
847
|
+
if (visual != nullptr)
|
|
848
|
+
matchedDepth = 16;
|
|
849
|
+
}
|
|
850
|
+
|
|
851
|
+
return visual;
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
|
|
855
|
+
//================================= X11 - Bitmap ===============================
|
|
856
|
+
class XBitmapImage final : public ImagePixelData
|
|
857
|
+
{
|
|
858
|
+
public:
|
|
859
|
+
explicit XBitmapImage (XImage* image)
|
|
860
|
+
: ImagePixelData (image->depth == 24 ? Image::RGB : Image::ARGB, image->width, image->height),
|
|
861
|
+
xImage (image),
|
|
862
|
+
imageDepth ((unsigned int) xImage->depth)
|
|
863
|
+
{
|
|
864
|
+
pixelStride = xImage->bits_per_pixel / 8;
|
|
865
|
+
lineStride = xImage->bytes_per_line;
|
|
866
|
+
imageData = reinterpret_cast<uint8*> (xImage->data);
|
|
867
|
+
}
|
|
868
|
+
|
|
869
|
+
XBitmapImage (Image::PixelFormat format, int w, int h,
|
|
870
|
+
bool clearImage, unsigned int imageDepth_, Visual* visual)
|
|
871
|
+
: ImagePixelData (format, w, h),
|
|
872
|
+
imageDepth (imageDepth_)
|
|
873
|
+
{
|
|
874
|
+
jassert (format == Image::RGB || format == Image::ARGB);
|
|
875
|
+
|
|
876
|
+
pixelStride = (format == Image::RGB) ? 3 : 4;
|
|
877
|
+
lineStride = ((w * pixelStride + 3) & ~3);
|
|
878
|
+
|
|
879
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
880
|
+
|
|
881
|
+
#if JUCE_USE_XSHM
|
|
882
|
+
usingXShm = false;
|
|
883
|
+
|
|
884
|
+
if ((imageDepth > 16) && XSHMHelpers::isShmAvailable (display))
|
|
885
|
+
{
|
|
886
|
+
zerostruct (segmentInfo);
|
|
887
|
+
|
|
888
|
+
segmentInfo.shmid = -1;
|
|
889
|
+
segmentInfo.shmaddr = (char *) -1;
|
|
890
|
+
segmentInfo.readOnly = False;
|
|
891
|
+
|
|
892
|
+
xImage.reset (X11Symbols::getInstance()->xShmCreateImage (display, visual, imageDepth, ZPixmap, nullptr,
|
|
893
|
+
&segmentInfo, (unsigned int) w, (unsigned int) h));
|
|
894
|
+
|
|
895
|
+
if (xImage != nullptr)
|
|
896
|
+
{
|
|
897
|
+
if ((segmentInfo.shmid = shmget (IPC_PRIVATE,
|
|
898
|
+
(size_t) (xImage->bytes_per_line * xImage->height),
|
|
899
|
+
IPC_CREAT | 0777)) >= 0)
|
|
900
|
+
{
|
|
901
|
+
if (segmentInfo.shmid != -1)
|
|
902
|
+
{
|
|
903
|
+
segmentInfo.shmaddr = (char*) shmat (segmentInfo.shmid, nullptr, 0);
|
|
904
|
+
|
|
905
|
+
if (segmentInfo.shmaddr != (void*) -1)
|
|
906
|
+
{
|
|
907
|
+
segmentInfo.readOnly = False;
|
|
908
|
+
|
|
909
|
+
xImage->data = segmentInfo.shmaddr;
|
|
910
|
+
imageData = (uint8*) segmentInfo.shmaddr;
|
|
911
|
+
|
|
912
|
+
if (X11Symbols::getInstance()->xShmAttach (display, &segmentInfo) != 0)
|
|
913
|
+
usingXShm = true;
|
|
914
|
+
else
|
|
915
|
+
jassertfalse;
|
|
916
|
+
}
|
|
917
|
+
else
|
|
918
|
+
{
|
|
919
|
+
shmctl (segmentInfo.shmid, IPC_RMID, nullptr);
|
|
920
|
+
}
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
|
|
926
|
+
if (! isUsingXShm())
|
|
927
|
+
#endif
|
|
928
|
+
{
|
|
929
|
+
imageDataAllocated.allocate ((size_t) (lineStride * h), format == Image::ARGB && clearImage);
|
|
930
|
+
imageData = imageDataAllocated;
|
|
931
|
+
|
|
932
|
+
xImage.reset ((XImage*) ::calloc (1, sizeof (XImage)));
|
|
933
|
+
|
|
934
|
+
xImage->width = w;
|
|
935
|
+
xImage->height = h;
|
|
936
|
+
xImage->xoffset = 0;
|
|
937
|
+
xImage->format = ZPixmap;
|
|
938
|
+
xImage->data = (char*) imageData;
|
|
939
|
+
xImage->byte_order = X11Symbols::getInstance()->xImageByteOrder (display);
|
|
940
|
+
xImage->bitmap_unit = X11Symbols::getInstance()->xBitmapUnit (display);
|
|
941
|
+
xImage->bitmap_bit_order = X11Symbols::getInstance()->xBitmapBitOrder (display);
|
|
942
|
+
xImage->bitmap_pad = 32;
|
|
943
|
+
xImage->depth = pixelStride * 8;
|
|
944
|
+
xImage->bytes_per_line = lineStride;
|
|
945
|
+
xImage->bits_per_pixel = pixelStride * 8;
|
|
946
|
+
xImage->red_mask = 0x00FF0000;
|
|
947
|
+
xImage->green_mask = 0x0000FF00;
|
|
948
|
+
xImage->blue_mask = 0x000000FF;
|
|
949
|
+
|
|
950
|
+
if (imageDepth == 16)
|
|
951
|
+
{
|
|
952
|
+
int pixStride = 2;
|
|
953
|
+
auto stride = ((w * pixStride + 3) & ~3);
|
|
954
|
+
|
|
955
|
+
imageData16Bit.malloc (stride * h);
|
|
956
|
+
xImage->data = imageData16Bit;
|
|
957
|
+
xImage->bitmap_pad = 16;
|
|
958
|
+
xImage->depth = pixStride * 8;
|
|
959
|
+
xImage->bytes_per_line = stride;
|
|
960
|
+
xImage->bits_per_pixel = pixStride * 8;
|
|
961
|
+
xImage->red_mask = visual->red_mask;
|
|
962
|
+
xImage->green_mask = visual->green_mask;
|
|
963
|
+
xImage->blue_mask = visual->blue_mask;
|
|
964
|
+
}
|
|
965
|
+
|
|
966
|
+
if (! X11Symbols::getInstance()->xInitImage (xImage.get()))
|
|
967
|
+
jassertfalse;
|
|
968
|
+
}
|
|
969
|
+
}
|
|
970
|
+
|
|
971
|
+
~XBitmapImage() override
|
|
972
|
+
{
|
|
973
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
974
|
+
|
|
975
|
+
if (gc != None)
|
|
976
|
+
X11Symbols::getInstance()->xFreeGC (display, gc);
|
|
977
|
+
|
|
978
|
+
#if JUCE_USE_XSHM
|
|
979
|
+
if (isUsingXShm())
|
|
980
|
+
{
|
|
981
|
+
X11Symbols::getInstance()->xShmDetach (display, &segmentInfo);
|
|
982
|
+
|
|
983
|
+
X11Symbols::getInstance()->xFlush (display);
|
|
984
|
+
|
|
985
|
+
shmdt (segmentInfo.shmaddr);
|
|
986
|
+
shmctl (segmentInfo.shmid, IPC_RMID, nullptr);
|
|
987
|
+
}
|
|
988
|
+
else
|
|
989
|
+
#endif
|
|
990
|
+
{
|
|
991
|
+
xImage->data = nullptr;
|
|
992
|
+
}
|
|
993
|
+
}
|
|
994
|
+
|
|
995
|
+
std::unique_ptr<LowLevelGraphicsContext> createLowLevelContext() override
|
|
996
|
+
{
|
|
997
|
+
sendDataChangeMessage();
|
|
998
|
+
return std::make_unique<LowLevelGraphicsSoftwareRenderer> (Image (this));
|
|
999
|
+
}
|
|
1000
|
+
|
|
1001
|
+
void initialiseBitmapData (Image::BitmapData& bitmap, int x, int y,
|
|
1002
|
+
Image::BitmapData::ReadWriteMode mode) override
|
|
1003
|
+
{
|
|
1004
|
+
const auto offset = (size_t) (x * pixelStride + y * lineStride);
|
|
1005
|
+
bitmap.data = imageData + offset;
|
|
1006
|
+
bitmap.size = (size_t) (lineStride * height) - offset;
|
|
1007
|
+
bitmap.pixelFormat = pixelFormat;
|
|
1008
|
+
bitmap.lineStride = lineStride;
|
|
1009
|
+
bitmap.pixelStride = pixelStride;
|
|
1010
|
+
|
|
1011
|
+
if (mode != Image::BitmapData::readOnly)
|
|
1012
|
+
sendDataChangeMessage();
|
|
1013
|
+
}
|
|
1014
|
+
|
|
1015
|
+
ImagePixelData::Ptr clone() override
|
|
1016
|
+
{
|
|
1017
|
+
jassertfalse;
|
|
1018
|
+
return nullptr;
|
|
1019
|
+
}
|
|
1020
|
+
|
|
1021
|
+
std::unique_ptr<ImageType> createType() const override { return std::make_unique<NativeImageType>(); }
|
|
1022
|
+
|
|
1023
|
+
void blitToWindow (::Window window, int dx, int dy, unsigned int dw, unsigned int dh, int sx, int sy)
|
|
1024
|
+
{
|
|
1025
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1026
|
+
|
|
1027
|
+
#if JUCE_USE_XSHM
|
|
1028
|
+
if (isUsingXShm())
|
|
1029
|
+
XWindowSystem::getInstance()->addPendingPaintForWindow (window);
|
|
1030
|
+
#endif
|
|
1031
|
+
|
|
1032
|
+
if (gc == None)
|
|
1033
|
+
{
|
|
1034
|
+
XGCValues gcvalues;
|
|
1035
|
+
gcvalues.foreground = None;
|
|
1036
|
+
gcvalues.background = None;
|
|
1037
|
+
gcvalues.function = GXcopy;
|
|
1038
|
+
gcvalues.plane_mask = AllPlanes;
|
|
1039
|
+
gcvalues.clip_mask = None;
|
|
1040
|
+
gcvalues.graphics_exposures = False;
|
|
1041
|
+
|
|
1042
|
+
gc = X11Symbols::getInstance()->xCreateGC (display, window,
|
|
1043
|
+
GCBackground | GCForeground | GCFunction | GCPlaneMask | GCClipMask | GCGraphicsExposures,
|
|
1044
|
+
&gcvalues);
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
if (imageDepth == 16)
|
|
1048
|
+
{
|
|
1049
|
+
auto rMask = (uint32) xImage->red_mask;
|
|
1050
|
+
auto gMask = (uint32) xImage->green_mask;
|
|
1051
|
+
auto bMask = (uint32) xImage->blue_mask;
|
|
1052
|
+
auto rShiftL = (uint32) jmax (0, getShiftNeeded (rMask));
|
|
1053
|
+
auto rShiftR = (uint32) jmax (0, -getShiftNeeded (rMask));
|
|
1054
|
+
auto gShiftL = (uint32) jmax (0, getShiftNeeded (gMask));
|
|
1055
|
+
auto gShiftR = (uint32) jmax (0, -getShiftNeeded (gMask));
|
|
1056
|
+
auto bShiftL = (uint32) jmax (0, getShiftNeeded (bMask));
|
|
1057
|
+
auto bShiftR = (uint32) jmax (0, -getShiftNeeded (bMask));
|
|
1058
|
+
|
|
1059
|
+
Image::BitmapData srcData (Image (this), Image::BitmapData::readOnly);
|
|
1060
|
+
|
|
1061
|
+
for (int y = sy; y < sy + (int) dh; ++y)
|
|
1062
|
+
{
|
|
1063
|
+
auto* p = srcData.getPixelPointer (sx, y);
|
|
1064
|
+
|
|
1065
|
+
for (int x = sx; x < sx + (int) dw; ++x)
|
|
1066
|
+
{
|
|
1067
|
+
auto* pixel = (PixelRGB*) p;
|
|
1068
|
+
p += srcData.pixelStride;
|
|
1069
|
+
|
|
1070
|
+
X11Symbols::getInstance()->xPutPixel (xImage.get(), x, y,
|
|
1071
|
+
(((((uint32) pixel->getRed()) << rShiftL) >> rShiftR) & rMask)
|
|
1072
|
+
| (((((uint32) pixel->getGreen()) << gShiftL) >> gShiftR) & gMask)
|
|
1073
|
+
| (((((uint32) pixel->getBlue()) << bShiftL) >> bShiftR) & bMask));
|
|
1074
|
+
}
|
|
1075
|
+
}
|
|
1076
|
+
}
|
|
1077
|
+
|
|
1078
|
+
// blit results to screen.
|
|
1079
|
+
#if JUCE_USE_XSHM
|
|
1080
|
+
if (isUsingXShm())
|
|
1081
|
+
X11Symbols::getInstance()->xShmPutImage (display, (::Drawable) window, gc, xImage.get(), sx, sy, dx, dy, dw, dh, True);
|
|
1082
|
+
else
|
|
1083
|
+
#endif
|
|
1084
|
+
X11Symbols::getInstance()->xPutImage (display, (::Drawable) window, gc, xImage.get(), sx, sy, dx, dy, dw, dh);
|
|
1085
|
+
}
|
|
1086
|
+
|
|
1087
|
+
#if JUCE_USE_XSHM
|
|
1088
|
+
bool isUsingXShm() const noexcept { return usingXShm; }
|
|
1089
|
+
#endif
|
|
1090
|
+
|
|
1091
|
+
private:
|
|
1092
|
+
//==============================================================================
|
|
1093
|
+
struct Deleter
|
|
1094
|
+
{
|
|
1095
|
+
void operator() (XImage* img) const noexcept
|
|
1096
|
+
{
|
|
1097
|
+
X11Symbols::getInstance()->xDestroyImage (img);
|
|
1098
|
+
}
|
|
1099
|
+
};
|
|
1100
|
+
|
|
1101
|
+
std::unique_ptr<XImage, Deleter> xImage;
|
|
1102
|
+
const unsigned int imageDepth;
|
|
1103
|
+
HeapBlock<uint8> imageDataAllocated;
|
|
1104
|
+
HeapBlock<char> imageData16Bit;
|
|
1105
|
+
int pixelStride, lineStride;
|
|
1106
|
+
uint8* imageData = nullptr;
|
|
1107
|
+
GC gc = None;
|
|
1108
|
+
::Display* display = XWindowSystem::getInstance()->getDisplay();
|
|
1109
|
+
|
|
1110
|
+
#if JUCE_USE_XSHM
|
|
1111
|
+
XShmSegmentInfo segmentInfo;
|
|
1112
|
+
bool usingXShm;
|
|
1113
|
+
#endif
|
|
1114
|
+
|
|
1115
|
+
static int getShiftNeeded (const uint32 mask) noexcept
|
|
1116
|
+
{
|
|
1117
|
+
for (int i = 32; --i >= 0;)
|
|
1118
|
+
if (((mask >> i) & 1) != 0)
|
|
1119
|
+
return i - 7;
|
|
1120
|
+
|
|
1121
|
+
jassertfalse;
|
|
1122
|
+
return 0;
|
|
1123
|
+
}
|
|
1124
|
+
|
|
1125
|
+
JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (XBitmapImage)
|
|
1126
|
+
};
|
|
1127
|
+
|
|
1128
|
+
//=============================== X11 - Displays ===============================
|
|
1129
|
+
namespace DisplayHelpers
|
|
1130
|
+
{
|
|
1131
|
+
static double getDisplayDPI (::Display* display, int index)
|
|
1132
|
+
{
|
|
1133
|
+
auto widthMM = X11Symbols::getInstance()->xDisplayWidthMM (display, index);
|
|
1134
|
+
auto heightMM = X11Symbols::getInstance()->xDisplayHeightMM (display, index);
|
|
1135
|
+
|
|
1136
|
+
if (widthMM > 0 && heightMM > 0)
|
|
1137
|
+
return (((X11Symbols::getInstance()->xDisplayWidth (display, index) * 25.4) / widthMM)
|
|
1138
|
+
+ ((X11Symbols::getInstance()->xDisplayHeight (display, index) * 25.4) / heightMM)) / 2.0;
|
|
1139
|
+
|
|
1140
|
+
return 96.0;
|
|
1141
|
+
}
|
|
1142
|
+
|
|
1143
|
+
static double getDisplayScale (const String& name, double dpi)
|
|
1144
|
+
{
|
|
1145
|
+
if (auto* xSettings = XWindowSystem::getInstance()->getXSettings())
|
|
1146
|
+
{
|
|
1147
|
+
auto windowScalingFactorSetting = xSettings->getSetting (XWindowSystem::getWindowScalingFactorSettingName());
|
|
1148
|
+
|
|
1149
|
+
if (windowScalingFactorSetting.isValid()
|
|
1150
|
+
&& windowScalingFactorSetting.integerValue > 0)
|
|
1151
|
+
{
|
|
1152
|
+
return (double) windowScalingFactorSetting.integerValue;
|
|
1153
|
+
}
|
|
1154
|
+
}
|
|
1155
|
+
|
|
1156
|
+
if (name.isNotEmpty())
|
|
1157
|
+
{
|
|
1158
|
+
// Ubuntu and derived distributions now save a per-display scale factor as a configuration
|
|
1159
|
+
// variable. This can be changed in the Monitor system settings panel.
|
|
1160
|
+
ChildProcess dconf;
|
|
1161
|
+
|
|
1162
|
+
if (File ("/usr/bin/dconf").existsAsFile()
|
|
1163
|
+
&& dconf.start ("/usr/bin/dconf read /com/ubuntu/user-interface/scale-factor", ChildProcess::wantStdOut))
|
|
1164
|
+
{
|
|
1165
|
+
if (dconf.waitForProcessToFinish (200))
|
|
1166
|
+
{
|
|
1167
|
+
auto jsonOutput = dconf.readAllProcessOutput().replaceCharacter ('\'', '"');
|
|
1168
|
+
|
|
1169
|
+
if (dconf.getExitCode() == 0 && jsonOutput.isNotEmpty())
|
|
1170
|
+
{
|
|
1171
|
+
auto jsonVar = JSON::parse (jsonOutput);
|
|
1172
|
+
|
|
1173
|
+
if (auto* object = jsonVar.getDynamicObject())
|
|
1174
|
+
{
|
|
1175
|
+
auto scaleFactorVar = object->getProperty (name);
|
|
1176
|
+
|
|
1177
|
+
if (! scaleFactorVar.isVoid())
|
|
1178
|
+
{
|
|
1179
|
+
auto scaleFactor = ((double) scaleFactorVar) / 8.0;
|
|
1180
|
+
|
|
1181
|
+
if (scaleFactor > 0.0)
|
|
1182
|
+
return scaleFactor;
|
|
1183
|
+
}
|
|
1184
|
+
}
|
|
1185
|
+
}
|
|
1186
|
+
}
|
|
1187
|
+
}
|
|
1188
|
+
}
|
|
1189
|
+
|
|
1190
|
+
{
|
|
1191
|
+
// Other gnome based distros now use gsettings for a global scale factor
|
|
1192
|
+
ChildProcess gsettings;
|
|
1193
|
+
|
|
1194
|
+
if (File ("/usr/bin/gsettings").existsAsFile()
|
|
1195
|
+
&& gsettings.start ("/usr/bin/gsettings get org.gnome.desktop.interface scaling-factor", ChildProcess::wantStdOut))
|
|
1196
|
+
{
|
|
1197
|
+
if (gsettings.waitForProcessToFinish (200))
|
|
1198
|
+
{
|
|
1199
|
+
auto gsettingsOutput = StringArray::fromTokens (gsettings.readAllProcessOutput(), true);
|
|
1200
|
+
|
|
1201
|
+
if (gsettingsOutput.size() >= 2 && gsettingsOutput[1].length() > 0)
|
|
1202
|
+
{
|
|
1203
|
+
auto scaleFactor = gsettingsOutput[1].getDoubleValue();
|
|
1204
|
+
|
|
1205
|
+
if (scaleFactor > 0.0)
|
|
1206
|
+
return scaleFactor;
|
|
1207
|
+
|
|
1208
|
+
return 1.0;
|
|
1209
|
+
}
|
|
1210
|
+
}
|
|
1211
|
+
}
|
|
1212
|
+
}
|
|
1213
|
+
|
|
1214
|
+
// If no scale factor is set by GNOME or Ubuntu then calculate from monitor dpi
|
|
1215
|
+
// We use the same approach as chromium which simply divides the dpi by 96
|
|
1216
|
+
// and then rounds the result
|
|
1217
|
+
return round (dpi / 96.0);
|
|
1218
|
+
}
|
|
1219
|
+
|
|
1220
|
+
#if JUCE_USE_XINERAMA
|
|
1221
|
+
static Array<XineramaScreenInfo> xineramaQueryDisplays (::Display* display)
|
|
1222
|
+
{
|
|
1223
|
+
int major_opcode, first_event, first_error;
|
|
1224
|
+
|
|
1225
|
+
if (X11Symbols::getInstance()->xQueryExtension (display, "XINERAMA", &major_opcode, &first_event, &first_error)
|
|
1226
|
+
&& (X11Symbols::getInstance()->xineramaIsActive (display) != 0))
|
|
1227
|
+
{
|
|
1228
|
+
int numScreens;
|
|
1229
|
+
|
|
1230
|
+
if (auto xinfo = makeXFreePtr (X11Symbols::getInstance()->xineramaQueryScreens (display, &numScreens)))
|
|
1231
|
+
return { xinfo.get(), numScreens };
|
|
1232
|
+
}
|
|
1233
|
+
|
|
1234
|
+
return {};
|
|
1235
|
+
}
|
|
1236
|
+
#endif
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
//=============================== X11 - Pixmap =================================
|
|
1240
|
+
namespace PixmapHelpers
|
|
1241
|
+
{
|
|
1242
|
+
static Pixmap createColourPixmapFromImage (::Display* display, const Image& image)
|
|
1243
|
+
{
|
|
1244
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1245
|
+
|
|
1246
|
+
auto width = (unsigned int) image.getWidth();
|
|
1247
|
+
auto height = (unsigned int) image.getHeight();
|
|
1248
|
+
HeapBlock<uint32> colour (width * height);
|
|
1249
|
+
int index = 0;
|
|
1250
|
+
|
|
1251
|
+
for (int y = 0; y < (int) height; ++y)
|
|
1252
|
+
for (int x = 0; x < (int) width; ++x)
|
|
1253
|
+
colour[index++] = image.getPixelAt (x, y).getARGB();
|
|
1254
|
+
|
|
1255
|
+
auto ximage = makeXFreePtr (X11Symbols::getInstance()->xCreateImage (display, (Visual*) CopyFromParent, 24, ZPixmap,
|
|
1256
|
+
0, reinterpret_cast<const char*> (colour.getData()),
|
|
1257
|
+
width, height, 32, 0));
|
|
1258
|
+
|
|
1259
|
+
auto pixmap = X11Symbols::getInstance()->xCreatePixmap (display,
|
|
1260
|
+
X11Symbols::getInstance()->xDefaultRootWindow (display),
|
|
1261
|
+
width, height, 24);
|
|
1262
|
+
|
|
1263
|
+
XValueHolder<GC> gc (X11Symbols::getInstance()->xCreateGC (display, pixmap, 0, nullptr),
|
|
1264
|
+
[&display] (GC& g) { X11Symbols::getInstance()->xFreeGC (display, g); });
|
|
1265
|
+
X11Symbols::getInstance()->xPutImage (display, pixmap, gc.value, ximage.get(), 0, 0, 0, 0, width, height);
|
|
1266
|
+
|
|
1267
|
+
return pixmap;
|
|
1268
|
+
}
|
|
1269
|
+
|
|
1270
|
+
static Pixmap createMaskPixmapFromImage (::Display* display, const Image& image)
|
|
1271
|
+
{
|
|
1272
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1273
|
+
|
|
1274
|
+
auto width = (unsigned int) image.getWidth();
|
|
1275
|
+
auto height = (unsigned int) image.getHeight();
|
|
1276
|
+
auto stride = (width + 7) >> 3;
|
|
1277
|
+
HeapBlock<char> mask;
|
|
1278
|
+
mask.calloc (stride * height);
|
|
1279
|
+
|
|
1280
|
+
auto msbfirst = (X11Symbols::getInstance()->xBitmapBitOrder (display) == MSBFirst);
|
|
1281
|
+
|
|
1282
|
+
for (unsigned int y = 0; y < height; ++y)
|
|
1283
|
+
{
|
|
1284
|
+
for (unsigned int x = 0; x < width; ++x)
|
|
1285
|
+
{
|
|
1286
|
+
auto bit = (char) (1 << (msbfirst ? (7 - (x & 7)) : (x & 7)));
|
|
1287
|
+
auto offset = y * stride + (x >> 3);
|
|
1288
|
+
|
|
1289
|
+
if (image.getPixelAt ((int) x, (int) y).getAlpha() >= 128)
|
|
1290
|
+
mask[offset] |= bit;
|
|
1291
|
+
}
|
|
1292
|
+
}
|
|
1293
|
+
|
|
1294
|
+
return X11Symbols::getInstance()->xCreatePixmapFromBitmapData (display, X11Symbols::getInstance()->xDefaultRootWindow (display),
|
|
1295
|
+
mask.getData(), width, height, 1, 0, 1);
|
|
1296
|
+
}
|
|
1297
|
+
}
|
|
1298
|
+
|
|
1299
|
+
//=============================== X11 - Clipboard ==============================
|
|
1300
|
+
namespace ClipboardHelpers
|
|
1301
|
+
{
|
|
1302
|
+
//==============================================================================
|
|
1303
|
+
// Read the content of a window property as either a locale-dependent string or an utf8 string
|
|
1304
|
+
// works only for strings shorter than 1000000 bytes
|
|
1305
|
+
static String readWindowProperty (::Display* display, Window window, Atom atom)
|
|
1306
|
+
{
|
|
1307
|
+
if (display != nullptr)
|
|
1308
|
+
{
|
|
1309
|
+
XWindowSystemUtilities::GetXProperty prop (display, window, atom, 0L, 100000, false, AnyPropertyType);
|
|
1310
|
+
|
|
1311
|
+
if (prop.success)
|
|
1312
|
+
{
|
|
1313
|
+
if (prop.actualType == XWindowSystem::getInstance()->getAtoms().utf8String && prop.actualFormat == 8)
|
|
1314
|
+
return String::fromUTF8 ((const char*) prop.data, (int) prop.numItems);
|
|
1315
|
+
|
|
1316
|
+
if (prop.actualType == XA_STRING && prop.actualFormat == 8)
|
|
1317
|
+
return String ((const char*) prop.data, prop.numItems);
|
|
1318
|
+
}
|
|
1319
|
+
}
|
|
1320
|
+
|
|
1321
|
+
return {};
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
//==============================================================================
|
|
1325
|
+
// Send a SelectionRequest to the window owning the selection and waits for its answer (with a timeout) */
|
|
1326
|
+
static bool requestSelectionContent (::Display* display, String& selectionContent, Atom selection, Atom requestedFormat)
|
|
1327
|
+
{
|
|
1328
|
+
auto property_name = X11Symbols::getInstance()->xInternAtom (display, "JUCE_SEL", false);
|
|
1329
|
+
|
|
1330
|
+
// The selection owner will be asked to set the JUCE_SEL property on the
|
|
1331
|
+
// juce_messageWindowHandle with the selection content
|
|
1332
|
+
X11Symbols::getInstance()->xConvertSelection (display, selection, requestedFormat, property_name,
|
|
1333
|
+
juce_messageWindowHandle, CurrentTime);
|
|
1334
|
+
|
|
1335
|
+
int count = 50; // will wait at most for 200 ms
|
|
1336
|
+
|
|
1337
|
+
while (--count >= 0)
|
|
1338
|
+
{
|
|
1339
|
+
XEvent event;
|
|
1340
|
+
|
|
1341
|
+
if (X11Symbols::getInstance()->xCheckTypedWindowEvent (display, juce_messageWindowHandle, SelectionNotify, &event))
|
|
1342
|
+
{
|
|
1343
|
+
if (event.xselection.property == property_name)
|
|
1344
|
+
{
|
|
1345
|
+
jassert (event.xselection.requestor == juce_messageWindowHandle);
|
|
1346
|
+
|
|
1347
|
+
selectionContent = readWindowProperty (display, event.xselection.requestor, event.xselection.property);
|
|
1348
|
+
return true;
|
|
1349
|
+
}
|
|
1350
|
+
|
|
1351
|
+
return false; // the format we asked for was denied.. (event.xselection.property == None)
|
|
1352
|
+
}
|
|
1353
|
+
|
|
1354
|
+
// not very elegant.. we could do a select() or something like that...
|
|
1355
|
+
// however clipboard content requesting is inherently slow on x11, it
|
|
1356
|
+
// often takes 50ms or more so...
|
|
1357
|
+
Thread::sleep (4);
|
|
1358
|
+
}
|
|
1359
|
+
|
|
1360
|
+
return false;
|
|
1361
|
+
}
|
|
1362
|
+
|
|
1363
|
+
//==============================================================================
|
|
1364
|
+
// Called from the event loop in juce_Messaging_linux in response to SelectionRequest events
|
|
1365
|
+
static void handleSelection (XSelectionRequestEvent& evt)
|
|
1366
|
+
{
|
|
1367
|
+
// the selection content is sent to the target window as a window property
|
|
1368
|
+
XSelectionEvent reply;
|
|
1369
|
+
reply.type = SelectionNotify;
|
|
1370
|
+
reply.display = evt.display;
|
|
1371
|
+
reply.requestor = evt.requestor;
|
|
1372
|
+
reply.selection = evt.selection;
|
|
1373
|
+
reply.target = evt.target;
|
|
1374
|
+
reply.property = None; // == "fail"
|
|
1375
|
+
reply.time = evt.time;
|
|
1376
|
+
|
|
1377
|
+
HeapBlock<char> data;
|
|
1378
|
+
int propertyFormat = 0;
|
|
1379
|
+
size_t numDataItems = 0;
|
|
1380
|
+
|
|
1381
|
+
const auto& atoms = XWindowSystem::getInstance()->getAtoms();
|
|
1382
|
+
|
|
1383
|
+
if (evt.selection == XA_PRIMARY || evt.selection == atoms.clipboard)
|
|
1384
|
+
{
|
|
1385
|
+
if (evt.target == XA_STRING || evt.target == atoms.utf8String)
|
|
1386
|
+
{
|
|
1387
|
+
auto localContent = XWindowSystem::getInstance()->getLocalClipboardContent();
|
|
1388
|
+
|
|
1389
|
+
// Translate to utf8
|
|
1390
|
+
numDataItems = localContent.getNumBytesAsUTF8();
|
|
1391
|
+
auto numBytesRequiredToStore = numDataItems + 1;
|
|
1392
|
+
data.calloc (numBytesRequiredToStore);
|
|
1393
|
+
localContent.copyToUTF8 (data, numBytesRequiredToStore);
|
|
1394
|
+
propertyFormat = 8; // bits per item
|
|
1395
|
+
}
|
|
1396
|
+
else if (evt.target == atoms.targets)
|
|
1397
|
+
{
|
|
1398
|
+
// Another application wants to know what we are able to send
|
|
1399
|
+
|
|
1400
|
+
numDataItems = 2;
|
|
1401
|
+
data.calloc (numDataItems * sizeof (Atom));
|
|
1402
|
+
|
|
1403
|
+
// Atoms are flagged as 32-bit irrespective of sizeof (Atom)
|
|
1404
|
+
propertyFormat = 32;
|
|
1405
|
+
|
|
1406
|
+
auto* dataAtoms = unalignedPointerCast<Atom*> (data.getData());
|
|
1407
|
+
|
|
1408
|
+
dataAtoms[0] = atoms.utf8String;
|
|
1409
|
+
dataAtoms[1] = XA_STRING;
|
|
1410
|
+
|
|
1411
|
+
evt.target = XA_ATOM;
|
|
1412
|
+
}
|
|
1413
|
+
}
|
|
1414
|
+
else
|
|
1415
|
+
{
|
|
1416
|
+
DBG ("requested unsupported clipboard");
|
|
1417
|
+
}
|
|
1418
|
+
|
|
1419
|
+
if (data != nullptr)
|
|
1420
|
+
{
|
|
1421
|
+
const size_t maxReasonableSelectionSize = 1000000;
|
|
1422
|
+
|
|
1423
|
+
// for very big chunks of data, we should use the "INCR" protocol , which is a pain in the *ss
|
|
1424
|
+
if (evt.property != None && numDataItems < maxReasonableSelectionSize)
|
|
1425
|
+
{
|
|
1426
|
+
X11Symbols::getInstance()->xChangeProperty (evt.display, evt.requestor,
|
|
1427
|
+
evt.property, evt.target,
|
|
1428
|
+
propertyFormat, PropModeReplace,
|
|
1429
|
+
reinterpret_cast<const unsigned char*> (data.getData()), (int) numDataItems);
|
|
1430
|
+
reply.property = evt.property; // " == success"
|
|
1431
|
+
}
|
|
1432
|
+
}
|
|
1433
|
+
|
|
1434
|
+
X11Symbols::getInstance()->xSendEvent (evt.display, evt.requestor, 0, NoEventMask, (XEvent*) &reply);
|
|
1435
|
+
}
|
|
1436
|
+
}
|
|
1437
|
+
|
|
1438
|
+
//==============================================================================
|
|
1439
|
+
ComponentPeer* getPeerFor (::Window windowH)
|
|
1440
|
+
{
|
|
1441
|
+
if (windowH == 0)
|
|
1442
|
+
return nullptr;
|
|
1443
|
+
|
|
1444
|
+
if (auto* display = XWindowSystem::getInstance()->getDisplay())
|
|
1445
|
+
{
|
|
1446
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1447
|
+
|
|
1448
|
+
if (XPointer peer = nullptr;
|
|
1449
|
+
X11Symbols::getInstance()->xFindContext (display,
|
|
1450
|
+
static_cast<XID> (windowH),
|
|
1451
|
+
windowHandleXContext,
|
|
1452
|
+
&peer) == 0)
|
|
1453
|
+
{
|
|
1454
|
+
return unalignedPointerCast<ComponentPeer*> (peer);
|
|
1455
|
+
}
|
|
1456
|
+
}
|
|
1457
|
+
|
|
1458
|
+
return nullptr;
|
|
1459
|
+
}
|
|
1460
|
+
|
|
1461
|
+
//==============================================================================
|
|
1462
|
+
static std::unordered_map<LinuxComponentPeer*, X11DragState> dragAndDropStateMap;
|
|
1463
|
+
|
|
1464
|
+
XWindowSystem::XWindowSystem()
|
|
1465
|
+
{
|
|
1466
|
+
xIsAvailable = X11Symbols::getInstance()->loadAllSymbols();
|
|
1467
|
+
|
|
1468
|
+
if (! xIsAvailable)
|
|
1469
|
+
return;
|
|
1470
|
+
|
|
1471
|
+
if (JUCEApplicationBase::isStandaloneApp())
|
|
1472
|
+
{
|
|
1473
|
+
// Initialise xlib for multiple thread support
|
|
1474
|
+
static bool initThreadCalled = false;
|
|
1475
|
+
|
|
1476
|
+
if (! initThreadCalled)
|
|
1477
|
+
{
|
|
1478
|
+
if (! X11Symbols::getInstance()->xInitThreads())
|
|
1479
|
+
{
|
|
1480
|
+
// This is fatal! Print error and closedown
|
|
1481
|
+
Logger::outputDebugString ("Failed to initialise xlib thread support.");
|
|
1482
|
+
Process::terminate();
|
|
1483
|
+
|
|
1484
|
+
return;
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
initThreadCalled = true;
|
|
1488
|
+
}
|
|
1489
|
+
|
|
1490
|
+
X11ErrorHandling::installXErrorHandlers();
|
|
1491
|
+
}
|
|
1492
|
+
|
|
1493
|
+
if (! initialiseXDisplay())
|
|
1494
|
+
{
|
|
1495
|
+
if (JUCEApplicationBase::isStandaloneApp())
|
|
1496
|
+
X11ErrorHandling::removeXErrorHandlers();
|
|
1497
|
+
|
|
1498
|
+
X11Symbols::deleteInstance();
|
|
1499
|
+
xIsAvailable = false;
|
|
1500
|
+
}
|
|
1501
|
+
}
|
|
1502
|
+
|
|
1503
|
+
XWindowSystem::~XWindowSystem()
|
|
1504
|
+
{
|
|
1505
|
+
if (xIsAvailable)
|
|
1506
|
+
{
|
|
1507
|
+
destroyXDisplay();
|
|
1508
|
+
|
|
1509
|
+
if (JUCEApplicationBase::isStandaloneApp())
|
|
1510
|
+
X11ErrorHandling::removeXErrorHandlers();
|
|
1511
|
+
}
|
|
1512
|
+
|
|
1513
|
+
X11Symbols::deleteInstance();
|
|
1514
|
+
clearSingletonInstance();
|
|
1515
|
+
}
|
|
1516
|
+
|
|
1517
|
+
//==============================================================================
|
|
1518
|
+
static int getAllEventsMask (bool ignoresMouseClicks)
|
|
1519
|
+
{
|
|
1520
|
+
return NoEventMask | KeyPressMask | KeyReleaseMask
|
|
1521
|
+
| EnterWindowMask | LeaveWindowMask | PointerMotionMask | KeymapStateMask
|
|
1522
|
+
| ExposureMask | StructureNotifyMask | FocusChangeMask | PropertyChangeMask
|
|
1523
|
+
| (ignoresMouseClicks ? 0 : (ButtonPressMask | ButtonReleaseMask));
|
|
1524
|
+
}
|
|
1525
|
+
|
|
1526
|
+
::Window XWindowSystem::createWindow (::Window parentToAddTo, LinuxComponentPeer* peer) const
|
|
1527
|
+
{
|
|
1528
|
+
if (! xIsAvailable)
|
|
1529
|
+
{
|
|
1530
|
+
// can't open a window on a system that doesn't have X11 installed!
|
|
1531
|
+
jassertfalse;
|
|
1532
|
+
return 0;
|
|
1533
|
+
}
|
|
1534
|
+
|
|
1535
|
+
auto styleFlags = peer->getStyleFlags();
|
|
1536
|
+
|
|
1537
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1538
|
+
|
|
1539
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
1540
|
+
|
|
1541
|
+
auto visualAndDepth = displayVisuals->getBestVisualForWindow ((styleFlags & ComponentPeer::windowIsSemiTransparent) != 0);
|
|
1542
|
+
|
|
1543
|
+
auto colormap = X11Symbols::getInstance()->xCreateColormap (display, root, visualAndDepth.visual, AllocNone);
|
|
1544
|
+
X11Symbols::getInstance()->xInstallColormap (display, colormap);
|
|
1545
|
+
|
|
1546
|
+
// Set up the window attributes
|
|
1547
|
+
XSetWindowAttributes swa;
|
|
1548
|
+
swa.border_pixel = 0;
|
|
1549
|
+
swa.background_pixmap = None;
|
|
1550
|
+
swa.colormap = colormap;
|
|
1551
|
+
swa.override_redirect = ((styleFlags & ComponentPeer::windowIsTemporary) != 0) ? True : False;
|
|
1552
|
+
swa.event_mask = getAllEventsMask (styleFlags & ComponentPeer::windowIgnoresMouseClicks);
|
|
1553
|
+
|
|
1554
|
+
auto windowH = X11Symbols::getInstance()->xCreateWindow (display, parentToAddTo != 0 ? parentToAddTo : root,
|
|
1555
|
+
0, 0, 1, 1,
|
|
1556
|
+
0, visualAndDepth.depth, InputOutput, visualAndDepth.visual,
|
|
1557
|
+
CWBorderPixel | CWColormap | CWBackPixmap | CWEventMask | CWOverrideRedirect,
|
|
1558
|
+
&swa);
|
|
1559
|
+
|
|
1560
|
+
// Set the window context to identify the window handle object
|
|
1561
|
+
if (! peer->setWindowAssociation (windowH))
|
|
1562
|
+
{
|
|
1563
|
+
// Failed
|
|
1564
|
+
jassertfalse;
|
|
1565
|
+
|
|
1566
|
+
Logger::outputDebugString ("Failed to create context information for window.\n");
|
|
1567
|
+
X11Symbols::getInstance()->xDestroyWindow (display, windowH);
|
|
1568
|
+
|
|
1569
|
+
return 0;
|
|
1570
|
+
}
|
|
1571
|
+
|
|
1572
|
+
// Set window manager hints
|
|
1573
|
+
if (auto wmHints = makeXFreePtr (X11Symbols::getInstance()->xAllocWMHints()))
|
|
1574
|
+
{
|
|
1575
|
+
wmHints->flags = InputHint | StateHint;
|
|
1576
|
+
wmHints->input = True;
|
|
1577
|
+
wmHints->initial_state = NormalState;
|
|
1578
|
+
X11Symbols::getInstance()->xSetWMHints (display, windowH, wmHints.get());
|
|
1579
|
+
}
|
|
1580
|
+
|
|
1581
|
+
// Set class hint
|
|
1582
|
+
if (auto* app = JUCEApplicationBase::getInstance())
|
|
1583
|
+
{
|
|
1584
|
+
if (auto classHint = makeXFreePtr (X11Symbols::getInstance()->xAllocClassHint()))
|
|
1585
|
+
{
|
|
1586
|
+
auto appName = app->getApplicationName();
|
|
1587
|
+
classHint->res_name = (char*) appName.getCharPointer().getAddress();
|
|
1588
|
+
classHint->res_class = (char*) appName.getCharPointer().getAddress();
|
|
1589
|
+
|
|
1590
|
+
X11Symbols::getInstance()->xSetClassHint (display, windowH, classHint.get());
|
|
1591
|
+
}
|
|
1592
|
+
}
|
|
1593
|
+
|
|
1594
|
+
// Set the window type
|
|
1595
|
+
setWindowType (windowH, styleFlags);
|
|
1596
|
+
|
|
1597
|
+
// Define decoration
|
|
1598
|
+
if ((styleFlags & ComponentPeer::windowHasTitleBar) == 0)
|
|
1599
|
+
removeWindowDecorations (windowH);
|
|
1600
|
+
else
|
|
1601
|
+
addWindowButtons (windowH, styleFlags);
|
|
1602
|
+
|
|
1603
|
+
// Associate the PID, allowing to be shut down when something goes wrong
|
|
1604
|
+
auto pid = (unsigned long) getpid();
|
|
1605
|
+
xchangeProperty (windowH, atoms.pid, XA_CARDINAL, 32, &pid, 1);
|
|
1606
|
+
|
|
1607
|
+
// Set window manager protocols
|
|
1608
|
+
xchangeProperty (windowH, atoms.protocols, XA_ATOM, 32, atoms.protocolList, 2);
|
|
1609
|
+
|
|
1610
|
+
// Set drag and drop flags
|
|
1611
|
+
xchangeProperty (windowH, atoms.XdndTypeList, XA_ATOM, 32, atoms.allowedMimeTypes, numElementsInArray (atoms.allowedMimeTypes));
|
|
1612
|
+
xchangeProperty (windowH, atoms.XdndActionList, XA_ATOM, 32, atoms.allowedActions, numElementsInArray (atoms.allowedActions));
|
|
1613
|
+
xchangeProperty (windowH, atoms.XdndActionDescription, XA_STRING, 8, "", 0);
|
|
1614
|
+
|
|
1615
|
+
auto dndVersion = XWindowSystemUtilities::Atoms::DndVersion;
|
|
1616
|
+
xchangeProperty (windowH, atoms.XdndAware, XA_ATOM, 32, &dndVersion, 1);
|
|
1617
|
+
|
|
1618
|
+
unsigned long info[2] = { 0, 1 };
|
|
1619
|
+
xchangeProperty (windowH, atoms.XembedInfo, atoms.XembedInfo, 32, (unsigned char*) info, 2);
|
|
1620
|
+
|
|
1621
|
+
return windowH;
|
|
1622
|
+
}
|
|
1623
|
+
|
|
1624
|
+
void XWindowSystem::destroyWindow (::Window windowH)
|
|
1625
|
+
{
|
|
1626
|
+
auto* peer = dynamic_cast<LinuxComponentPeer*> (getPeerFor (windowH));
|
|
1627
|
+
|
|
1628
|
+
if (peer == nullptr)
|
|
1629
|
+
{
|
|
1630
|
+
jassertfalse;
|
|
1631
|
+
return;
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1634
|
+
#if JUCE_X11_SUPPORTS_XEMBED
|
|
1635
|
+
juce_handleXEmbedEvent (peer, nullptr);
|
|
1636
|
+
#endif
|
|
1637
|
+
|
|
1638
|
+
deleteIconPixmaps (windowH);
|
|
1639
|
+
dragAndDropStateMap.erase (peer);
|
|
1640
|
+
|
|
1641
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1642
|
+
|
|
1643
|
+
peer->clearWindowAssociation();
|
|
1644
|
+
|
|
1645
|
+
X11Symbols::getInstance()->xDestroyWindow (display, windowH);
|
|
1646
|
+
|
|
1647
|
+
// Wait for it to complete and then remove any events for this
|
|
1648
|
+
// window from the event queue.
|
|
1649
|
+
X11Symbols::getInstance()->xSync (display, false);
|
|
1650
|
+
|
|
1651
|
+
XEvent event;
|
|
1652
|
+
while (X11Symbols::getInstance()->xCheckWindowEvent (display, windowH,
|
|
1653
|
+
getAllEventsMask (peer->getStyleFlags() & ComponentPeer::windowIgnoresMouseClicks),
|
|
1654
|
+
&event) == True)
|
|
1655
|
+
{}
|
|
1656
|
+
|
|
1657
|
+
#if JUCE_USE_XSHM
|
|
1658
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
1659
|
+
shmPaintsPendingMap.erase (windowH);
|
|
1660
|
+
#endif
|
|
1661
|
+
}
|
|
1662
|
+
|
|
1663
|
+
//==============================================================================
|
|
1664
|
+
void XWindowSystem::setTitle (::Window windowH, const String& title) const
|
|
1665
|
+
{
|
|
1666
|
+
jassert (windowH != 0);
|
|
1667
|
+
|
|
1668
|
+
XTextProperty nameProperty{};
|
|
1669
|
+
char* strings[] = { const_cast<char*> (title.toRawUTF8()) };
|
|
1670
|
+
|
|
1671
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1672
|
+
|
|
1673
|
+
if (X11Symbols::getInstance()->xutf8TextListToTextProperty (display,
|
|
1674
|
+
strings,
|
|
1675
|
+
numElementsInArray (strings),
|
|
1676
|
+
XUTF8StringStyle,
|
|
1677
|
+
&nameProperty) >= 0)
|
|
1678
|
+
{
|
|
1679
|
+
X11Symbols::getInstance()->xSetWMName (display, windowH, &nameProperty);
|
|
1680
|
+
X11Symbols::getInstance()->xSetWMIconName (display, windowH, &nameProperty);
|
|
1681
|
+
|
|
1682
|
+
X11Symbols::getInstance()->xFree (nameProperty.value);
|
|
1683
|
+
}
|
|
1684
|
+
}
|
|
1685
|
+
|
|
1686
|
+
|
|
1687
|
+
void XWindowSystem::setIcon (::Window windowH, const Image& newIcon) const
|
|
1688
|
+
{
|
|
1689
|
+
jassert (windowH != 0);
|
|
1690
|
+
|
|
1691
|
+
auto dataSize = newIcon.getWidth() * newIcon.getHeight() + 2;
|
|
1692
|
+
HeapBlock<unsigned long> data (dataSize);
|
|
1693
|
+
|
|
1694
|
+
int index = 0;
|
|
1695
|
+
data[index++] = (unsigned long) newIcon.getWidth();
|
|
1696
|
+
data[index++] = (unsigned long) newIcon.getHeight();
|
|
1697
|
+
|
|
1698
|
+
for (int y = 0; y < newIcon.getHeight(); ++y)
|
|
1699
|
+
for (int x = 0; x < newIcon.getWidth(); ++x)
|
|
1700
|
+
data[index++] = (unsigned long) newIcon.getPixelAt (x, y).getARGB();
|
|
1701
|
+
|
|
1702
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1703
|
+
xchangeProperty (windowH, XWindowSystemUtilities::Atoms::getCreating (display, "_NET_WM_ICON"),
|
|
1704
|
+
XA_CARDINAL, 32, data.getData(), dataSize);
|
|
1705
|
+
|
|
1706
|
+
deleteIconPixmaps (windowH);
|
|
1707
|
+
|
|
1708
|
+
auto wmHints = makeXFreePtr (X11Symbols::getInstance()->xGetWMHints (display, windowH));
|
|
1709
|
+
|
|
1710
|
+
if (wmHints == nullptr)
|
|
1711
|
+
wmHints = makeXFreePtr (X11Symbols::getInstance()->xAllocWMHints());
|
|
1712
|
+
|
|
1713
|
+
if (wmHints != nullptr)
|
|
1714
|
+
{
|
|
1715
|
+
wmHints->flags |= IconPixmapHint | IconMaskHint;
|
|
1716
|
+
wmHints->icon_pixmap = PixmapHelpers::createColourPixmapFromImage (display, newIcon);
|
|
1717
|
+
wmHints->icon_mask = PixmapHelpers::createMaskPixmapFromImage (display, newIcon);
|
|
1718
|
+
|
|
1719
|
+
X11Symbols::getInstance()->xSetWMHints (display, windowH, wmHints.get());
|
|
1720
|
+
}
|
|
1721
|
+
|
|
1722
|
+
X11Symbols::getInstance()->xSync (display, False);
|
|
1723
|
+
}
|
|
1724
|
+
|
|
1725
|
+
void XWindowSystem::setVisible (::Window windowH, bool shouldBeVisible) const
|
|
1726
|
+
{
|
|
1727
|
+
jassert (windowH != 0);
|
|
1728
|
+
|
|
1729
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1730
|
+
|
|
1731
|
+
if (shouldBeVisible)
|
|
1732
|
+
X11Symbols::getInstance()->xMapWindow (display, windowH);
|
|
1733
|
+
else
|
|
1734
|
+
X11Symbols::getInstance()->xUnmapWindow (display, windowH);
|
|
1735
|
+
}
|
|
1736
|
+
|
|
1737
|
+
void XWindowSystem::setBounds (::Window windowH, Rectangle<int> newBounds, bool isFullScreen) const
|
|
1738
|
+
{
|
|
1739
|
+
jassert (windowH != 0);
|
|
1740
|
+
|
|
1741
|
+
if (auto* peer = getPeerFor (windowH))
|
|
1742
|
+
{
|
|
1743
|
+
if (peer->isFullScreen() && ! isFullScreen)
|
|
1744
|
+
{
|
|
1745
|
+
// When transitioning back from fullscreen, we might need to remove
|
|
1746
|
+
// the FULLSCREEN window property
|
|
1747
|
+
Atom fs = XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WM_STATE_FULLSCREEN");
|
|
1748
|
+
|
|
1749
|
+
if (fs != None)
|
|
1750
|
+
{
|
|
1751
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
1752
|
+
|
|
1753
|
+
XClientMessageEvent clientMsg;
|
|
1754
|
+
clientMsg.display = display;
|
|
1755
|
+
clientMsg.window = windowH;
|
|
1756
|
+
clientMsg.type = ClientMessage;
|
|
1757
|
+
clientMsg.format = 32;
|
|
1758
|
+
clientMsg.message_type = atoms.windowState;
|
|
1759
|
+
clientMsg.data.l[0] = 0; // Remove
|
|
1760
|
+
clientMsg.data.l[1] = (long) fs;
|
|
1761
|
+
clientMsg.data.l[2] = 0;
|
|
1762
|
+
clientMsg.data.l[3] = 1; // Normal Source
|
|
1763
|
+
|
|
1764
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1765
|
+
X11Symbols::getInstance()->xSendEvent (display, root, false,
|
|
1766
|
+
SubstructureRedirectMask | SubstructureNotifyMask,
|
|
1767
|
+
(XEvent*) &clientMsg);
|
|
1768
|
+
}
|
|
1769
|
+
}
|
|
1770
|
+
|
|
1771
|
+
updateConstraints (windowH, *peer);
|
|
1772
|
+
|
|
1773
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1774
|
+
|
|
1775
|
+
if (auto hints = makeXFreePtr (X11Symbols::getInstance()->xAllocSizeHints()))
|
|
1776
|
+
{
|
|
1777
|
+
hints->flags = USSize | USPosition;
|
|
1778
|
+
hints->x = newBounds.getX();
|
|
1779
|
+
hints->y = newBounds.getY();
|
|
1780
|
+
hints->width = newBounds.getWidth();
|
|
1781
|
+
hints->height = newBounds.getHeight();
|
|
1782
|
+
X11Symbols::getInstance()->xSetWMNormalHints (display, windowH, hints.get());
|
|
1783
|
+
}
|
|
1784
|
+
|
|
1785
|
+
const auto nativeWindowBorder = [&]() -> BorderSize<int>
|
|
1786
|
+
{
|
|
1787
|
+
if (const auto& frameSize = peer->getFrameSizeIfPresent())
|
|
1788
|
+
return frameSize->multipliedBy (peer->getPlatformScaleFactor());
|
|
1789
|
+
|
|
1790
|
+
return {};
|
|
1791
|
+
}();
|
|
1792
|
+
|
|
1793
|
+
X11Symbols::getInstance()->xMoveResizeWindow (display, windowH,
|
|
1794
|
+
newBounds.getX() - nativeWindowBorder.getLeft(),
|
|
1795
|
+
newBounds.getY() - nativeWindowBorder.getTop(),
|
|
1796
|
+
(unsigned int) newBounds.getWidth(),
|
|
1797
|
+
(unsigned int) newBounds.getHeight());
|
|
1798
|
+
}
|
|
1799
|
+
}
|
|
1800
|
+
|
|
1801
|
+
void XWindowSystem::startHostManagedResize (::Window windowH,
|
|
1802
|
+
ResizableBorderComponent::Zone zone)
|
|
1803
|
+
{
|
|
1804
|
+
const auto moveResize = XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WM_MOVERESIZE");
|
|
1805
|
+
|
|
1806
|
+
if (moveResize == None)
|
|
1807
|
+
return;
|
|
1808
|
+
|
|
1809
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1810
|
+
|
|
1811
|
+
X11Symbols::getInstance()->xUngrabPointer (display, CurrentTime);
|
|
1812
|
+
|
|
1813
|
+
const auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
1814
|
+
const auto mouseDown = getCurrentMousePosition();
|
|
1815
|
+
|
|
1816
|
+
XClientMessageEvent clientMsg;
|
|
1817
|
+
clientMsg.display = display;
|
|
1818
|
+
clientMsg.window = windowH;
|
|
1819
|
+
clientMsg.type = ClientMessage;
|
|
1820
|
+
clientMsg.format = 32;
|
|
1821
|
+
clientMsg.message_type = moveResize;
|
|
1822
|
+
clientMsg.data.l[0] = (long) mouseDown.x;
|
|
1823
|
+
clientMsg.data.l[1] = (long) mouseDown.y;
|
|
1824
|
+
clientMsg.data.l[2] = [&]
|
|
1825
|
+
{
|
|
1826
|
+
// It's unclear which header is supposed to contain these
|
|
1827
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_TOPLEFT = 0;
|
|
1828
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_TOP = 1;
|
|
1829
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_TOPRIGHT = 2;
|
|
1830
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_RIGHT = 3;
|
|
1831
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_BOTTOMRIGHT = 4;
|
|
1832
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_BOTTOM = 5;
|
|
1833
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_BOTTOMLEFT = 6;
|
|
1834
|
+
static constexpr auto _NET_WM_MOVERESIZE_SIZE_LEFT = 7;
|
|
1835
|
+
static constexpr auto _NET_WM_MOVERESIZE_MOVE = 8;
|
|
1836
|
+
|
|
1837
|
+
using F = ResizableBorderComponent::Zone::Zones;
|
|
1838
|
+
|
|
1839
|
+
switch (zone.getZoneFlags())
|
|
1840
|
+
{
|
|
1841
|
+
case F::top | F::left: return _NET_WM_MOVERESIZE_SIZE_TOPLEFT;
|
|
1842
|
+
case F::top: return _NET_WM_MOVERESIZE_SIZE_TOP;
|
|
1843
|
+
case F::top | F::right: return _NET_WM_MOVERESIZE_SIZE_TOPRIGHT;
|
|
1844
|
+
case F::right: return _NET_WM_MOVERESIZE_SIZE_RIGHT;
|
|
1845
|
+
case F::bottom | F::right: return _NET_WM_MOVERESIZE_SIZE_BOTTOMRIGHT;
|
|
1846
|
+
case F::bottom: return _NET_WM_MOVERESIZE_SIZE_BOTTOM;
|
|
1847
|
+
case F::bottom | F::left: return _NET_WM_MOVERESIZE_SIZE_BOTTOMLEFT;
|
|
1848
|
+
case F::left: return _NET_WM_MOVERESIZE_SIZE_LEFT;
|
|
1849
|
+
}
|
|
1850
|
+
|
|
1851
|
+
return _NET_WM_MOVERESIZE_MOVE;
|
|
1852
|
+
}();
|
|
1853
|
+
clientMsg.data.l[3] = 0;
|
|
1854
|
+
clientMsg.data.l[4] = 1;
|
|
1855
|
+
|
|
1856
|
+
X11Symbols::getInstance()->xSendEvent (display,
|
|
1857
|
+
root,
|
|
1858
|
+
false,
|
|
1859
|
+
SubstructureRedirectMask | SubstructureNotifyMask,
|
|
1860
|
+
unalignedPointerCast<XEvent*> (&clientMsg));
|
|
1861
|
+
}
|
|
1862
|
+
|
|
1863
|
+
void XWindowSystem::updateConstraints (::Window windowH) const
|
|
1864
|
+
{
|
|
1865
|
+
if (auto* peer = getPeerFor (windowH))
|
|
1866
|
+
updateConstraints (windowH, *peer);
|
|
1867
|
+
}
|
|
1868
|
+
|
|
1869
|
+
void XWindowSystem::updateConstraints (::Window windowH, ComponentPeer& peer) const
|
|
1870
|
+
{
|
|
1871
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1872
|
+
|
|
1873
|
+
if (auto hints = makeXFreePtr (X11Symbols::getInstance()->xAllocSizeHints()))
|
|
1874
|
+
{
|
|
1875
|
+
if ((peer.getStyleFlags() & ComponentPeer::windowIsResizable) == 0)
|
|
1876
|
+
{
|
|
1877
|
+
hints->min_width = hints->max_width = peer.getBounds().getWidth();
|
|
1878
|
+
hints->min_height = hints->max_height = peer.getBounds().getHeight();
|
|
1879
|
+
hints->flags = PMinSize | PMaxSize;
|
|
1880
|
+
}
|
|
1881
|
+
else if (auto* c = peer.getConstrainer())
|
|
1882
|
+
{
|
|
1883
|
+
const auto windowBorder = [&]() -> BorderSize<int>
|
|
1884
|
+
{
|
|
1885
|
+
if (const auto& frameSize = peer.getFrameSizeIfPresent())
|
|
1886
|
+
return *frameSize;
|
|
1887
|
+
|
|
1888
|
+
return {};
|
|
1889
|
+
}();
|
|
1890
|
+
|
|
1891
|
+
const auto factor = peer.getPlatformScaleFactor();
|
|
1892
|
+
const auto leftAndRight = windowBorder.getLeftAndRight();
|
|
1893
|
+
const auto topAndBottom = windowBorder.getTopAndBottom();
|
|
1894
|
+
hints->min_width = jmax (1, (int) (factor * c->getMinimumWidth()) - leftAndRight);
|
|
1895
|
+
hints->max_width = jmax (1, (int) (factor * c->getMaximumWidth()) - leftAndRight);
|
|
1896
|
+
hints->min_height = jmax (1, (int) (factor * c->getMinimumHeight()) - topAndBottom);
|
|
1897
|
+
hints->max_height = jmax (1, (int) (factor * c->getMaximumHeight()) - topAndBottom);
|
|
1898
|
+
hints->flags = PMinSize | PMaxSize;
|
|
1899
|
+
}
|
|
1900
|
+
|
|
1901
|
+
X11Symbols::getInstance()->xSetWMNormalHints (display, windowH, hints.get());
|
|
1902
|
+
}
|
|
1903
|
+
}
|
|
1904
|
+
|
|
1905
|
+
bool XWindowSystem::contains (::Window windowH, Point<int> localPos) const
|
|
1906
|
+
{
|
|
1907
|
+
::Window root, child;
|
|
1908
|
+
int wx, wy;
|
|
1909
|
+
unsigned int ww, wh, bw, bitDepth;
|
|
1910
|
+
|
|
1911
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1912
|
+
|
|
1913
|
+
return X11Symbols::getInstance()->xGetGeometry (display, (::Drawable) windowH, &root, &wx, &wy, &ww, &wh, &bw, &bitDepth)
|
|
1914
|
+
&& X11Symbols::getInstance()->xTranslateCoordinates (display, windowH, windowH, localPos.getX(), localPos.getY(), &wx, &wy, &child)
|
|
1915
|
+
&& child == None;
|
|
1916
|
+
}
|
|
1917
|
+
|
|
1918
|
+
ComponentPeer::OptionalBorderSize XWindowSystem::getBorderSize (::Window windowH) const
|
|
1919
|
+
{
|
|
1920
|
+
jassert (windowH != 0);
|
|
1921
|
+
|
|
1922
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1923
|
+
auto hints = XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_FRAME_EXTENTS");
|
|
1924
|
+
|
|
1925
|
+
if (hints != None)
|
|
1926
|
+
{
|
|
1927
|
+
XWindowSystemUtilities::GetXProperty prop (display, windowH, hints, 0, 4, false, XA_CARDINAL);
|
|
1928
|
+
|
|
1929
|
+
if (prop.success && prop.actualFormat == 32)
|
|
1930
|
+
{
|
|
1931
|
+
auto data = prop.data;
|
|
1932
|
+
std::array<unsigned long, 4> sizes;
|
|
1933
|
+
|
|
1934
|
+
for (auto& size : sizes)
|
|
1935
|
+
{
|
|
1936
|
+
memcpy (&size, data, sizeof (unsigned long));
|
|
1937
|
+
data += sizeof (unsigned long);
|
|
1938
|
+
}
|
|
1939
|
+
|
|
1940
|
+
return ComponentPeer::OptionalBorderSize ({ (int) sizes[2], (int) sizes[0], (int) sizes[3], (int) sizes[1] });
|
|
1941
|
+
}
|
|
1942
|
+
}
|
|
1943
|
+
|
|
1944
|
+
return {};
|
|
1945
|
+
}
|
|
1946
|
+
|
|
1947
|
+
Rectangle<int> XWindowSystem::getWindowBounds (::Window windowH, ::Window parentWindow)
|
|
1948
|
+
{
|
|
1949
|
+
jassert (windowH != 0);
|
|
1950
|
+
|
|
1951
|
+
Window root, child;
|
|
1952
|
+
int wx = 0, wy = 0;
|
|
1953
|
+
unsigned int ww = 0, wh = 0, bw, bitDepth;
|
|
1954
|
+
|
|
1955
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
1956
|
+
|
|
1957
|
+
if (X11Symbols::getInstance()->xGetGeometry (display, (::Drawable) windowH, &root, &wx, &wy, &ww, &wh, &bw, &bitDepth))
|
|
1958
|
+
{
|
|
1959
|
+
int rootX = 0, rootY = 0;
|
|
1960
|
+
|
|
1961
|
+
if (! X11Symbols::getInstance()->xTranslateCoordinates (display, windowH, root, 0, 0, &rootX, &rootY, &child))
|
|
1962
|
+
rootX = rootY = 0;
|
|
1963
|
+
|
|
1964
|
+
if (parentWindow == 0)
|
|
1965
|
+
{
|
|
1966
|
+
wx = rootX;
|
|
1967
|
+
wy = rootY;
|
|
1968
|
+
}
|
|
1969
|
+
else
|
|
1970
|
+
{
|
|
1971
|
+
// XGetGeometry returns wx and wy relative to the parent window's origin.
|
|
1972
|
+
// XTranslateCoordinates returns rootX and rootY relative to the root window.
|
|
1973
|
+
parentScreenPosition = Point<int> (rootX - wx, rootY - wy);
|
|
1974
|
+
}
|
|
1975
|
+
}
|
|
1976
|
+
|
|
1977
|
+
return { wx, wy, (int) ww, (int) wh };
|
|
1978
|
+
}
|
|
1979
|
+
|
|
1980
|
+
Point<int> XWindowSystem::getPhysicalParentScreenPosition() const
|
|
1981
|
+
{
|
|
1982
|
+
return parentScreenPosition;
|
|
1983
|
+
}
|
|
1984
|
+
|
|
1985
|
+
void XWindowSystem::setMinimised (::Window windowH, bool shouldBeMinimised) const
|
|
1986
|
+
{
|
|
1987
|
+
jassert (windowH != 0);
|
|
1988
|
+
|
|
1989
|
+
if (shouldBeMinimised)
|
|
1990
|
+
{
|
|
1991
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
1992
|
+
|
|
1993
|
+
XClientMessageEvent clientMsg;
|
|
1994
|
+
clientMsg.display = display;
|
|
1995
|
+
clientMsg.window = windowH;
|
|
1996
|
+
clientMsg.type = ClientMessage;
|
|
1997
|
+
clientMsg.format = 32;
|
|
1998
|
+
clientMsg.message_type = atoms.changeState;
|
|
1999
|
+
clientMsg.data.l[0] = IconicState;
|
|
2000
|
+
|
|
2001
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2002
|
+
X11Symbols::getInstance()->xSendEvent (display, root, false, SubstructureRedirectMask | SubstructureNotifyMask, (XEvent*) &clientMsg);
|
|
2003
|
+
}
|
|
2004
|
+
}
|
|
2005
|
+
|
|
2006
|
+
bool XWindowSystem::isMinimised (::Window w) const
|
|
2007
|
+
{
|
|
2008
|
+
return isHidden (w);
|
|
2009
|
+
}
|
|
2010
|
+
|
|
2011
|
+
void XWindowSystem::setMaximised (::Window windowH, bool shouldBeMaximised) const
|
|
2012
|
+
{
|
|
2013
|
+
const auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
2014
|
+
|
|
2015
|
+
XEvent ev;
|
|
2016
|
+
ev.xclient.window = windowH;
|
|
2017
|
+
ev.xclient.type = ClientMessage;
|
|
2018
|
+
ev.xclient.format = 32;
|
|
2019
|
+
ev.xclient.message_type = XWindowSystemUtilities::Atoms::getCreating (display, "_NET_WM_STATE");
|
|
2020
|
+
ev.xclient.data.l[0] = shouldBeMaximised;
|
|
2021
|
+
ev.xclient.data.l[1] = (long) XWindowSystemUtilities::Atoms::getCreating (display, "_NET_WM_STATE_MAXIMIZED_HORZ");
|
|
2022
|
+
ev.xclient.data.l[2] = (long) XWindowSystemUtilities::Atoms::getCreating (display, "_NET_WM_STATE_MAXIMIZED_VERT");
|
|
2023
|
+
ev.xclient.data.l[3] = 1;
|
|
2024
|
+
ev.xclient.data.l[4] = 0;
|
|
2025
|
+
|
|
2026
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2027
|
+
X11Symbols::getInstance()->xSendEvent (display, root, false, SubstructureRedirectMask | SubstructureNotifyMask, &ev);
|
|
2028
|
+
}
|
|
2029
|
+
|
|
2030
|
+
void XWindowSystem::toFront (::Window windowH, bool) const
|
|
2031
|
+
{
|
|
2032
|
+
jassert (windowH != 0);
|
|
2033
|
+
|
|
2034
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2035
|
+
XEvent ev;
|
|
2036
|
+
ev.xclient.type = ClientMessage;
|
|
2037
|
+
ev.xclient.serial = 0;
|
|
2038
|
+
ev.xclient.send_event = True;
|
|
2039
|
+
ev.xclient.message_type = atoms.activeWin;
|
|
2040
|
+
ev.xclient.window = windowH;
|
|
2041
|
+
ev.xclient.format = 32;
|
|
2042
|
+
ev.xclient.data.l[0] = 2;
|
|
2043
|
+
ev.xclient.data.l[1] = getUserTime (windowH);
|
|
2044
|
+
ev.xclient.data.l[2] = 0;
|
|
2045
|
+
ev.xclient.data.l[3] = 0;
|
|
2046
|
+
ev.xclient.data.l[4] = 0;
|
|
2047
|
+
|
|
2048
|
+
X11Symbols::getInstance()->xSendEvent (display, X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
2049
|
+
False, SubstructureRedirectMask | SubstructureNotifyMask, &ev);
|
|
2050
|
+
|
|
2051
|
+
X11Symbols::getInstance()->xSync (display, False);
|
|
2052
|
+
}
|
|
2053
|
+
|
|
2054
|
+
void XWindowSystem::toBehind (::Window windowH, ::Window otherWindow) const
|
|
2055
|
+
{
|
|
2056
|
+
jassert (windowH != 0 && otherWindow != 0);
|
|
2057
|
+
|
|
2058
|
+
const auto topLevelA = findTopLevelWindowOf (windowH);
|
|
2059
|
+
const auto topLevelB = findTopLevelWindowOf (otherWindow);
|
|
2060
|
+
|
|
2061
|
+
Window newStack[] = { topLevelA, topLevelB };
|
|
2062
|
+
|
|
2063
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2064
|
+
X11Symbols::getInstance()->xRestackWindows (display, newStack, numElementsInArray (newStack));
|
|
2065
|
+
}
|
|
2066
|
+
|
|
2067
|
+
bool XWindowSystem::isFocused (::Window windowH) const
|
|
2068
|
+
{
|
|
2069
|
+
jassert (windowH != 0);
|
|
2070
|
+
|
|
2071
|
+
int revert = 0;
|
|
2072
|
+
Window focusedWindow = 0;
|
|
2073
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2074
|
+
X11Symbols::getInstance()->xGetInputFocus (display, &focusedWindow, &revert);
|
|
2075
|
+
|
|
2076
|
+
if (focusedWindow == PointerRoot)
|
|
2077
|
+
return false;
|
|
2078
|
+
|
|
2079
|
+
return isParentWindowOf (windowH, focusedWindow);
|
|
2080
|
+
}
|
|
2081
|
+
|
|
2082
|
+
::Window XWindowSystem::getFocusWindow (::Window windowH) const
|
|
2083
|
+
{
|
|
2084
|
+
jassert (windowH != 0);
|
|
2085
|
+
|
|
2086
|
+
#if JUCE_X11_SUPPORTS_XEMBED
|
|
2087
|
+
if (auto w = (::Window) juce_getCurrentFocusWindow (dynamic_cast<LinuxComponentPeer*> (getPeerFor (windowH))))
|
|
2088
|
+
return w;
|
|
2089
|
+
#endif
|
|
2090
|
+
|
|
2091
|
+
return windowH;
|
|
2092
|
+
}
|
|
2093
|
+
|
|
2094
|
+
bool XWindowSystem::grabFocus (::Window windowH) const
|
|
2095
|
+
{
|
|
2096
|
+
jassert (windowH != 0);
|
|
2097
|
+
|
|
2098
|
+
XWindowAttributes atts;
|
|
2099
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2100
|
+
|
|
2101
|
+
if (windowH != 0
|
|
2102
|
+
&& X11Symbols::getInstance()->xGetWindowAttributes (display, windowH, &atts)
|
|
2103
|
+
&& atts.map_state == IsViewable
|
|
2104
|
+
&& ! isFocused (windowH))
|
|
2105
|
+
{
|
|
2106
|
+
X11Symbols::getInstance()->xSetInputFocus (display, getFocusWindow (windowH), RevertToParent, (::Time) getUserTime (windowH));
|
|
2107
|
+
return true;
|
|
2108
|
+
}
|
|
2109
|
+
|
|
2110
|
+
return false;
|
|
2111
|
+
}
|
|
2112
|
+
|
|
2113
|
+
bool XWindowSystem::canUseSemiTransparentWindows() const
|
|
2114
|
+
{
|
|
2115
|
+
#if JUCE_USE_XRENDER
|
|
2116
|
+
if (XRender::hasCompositingWindowManager (display))
|
|
2117
|
+
{
|
|
2118
|
+
int matchedDepth = 0, desiredDepth = 32;
|
|
2119
|
+
|
|
2120
|
+
return Visuals::findVisualFormat (display, desiredDepth, matchedDepth) != nullptr
|
|
2121
|
+
&& matchedDepth == desiredDepth;
|
|
2122
|
+
}
|
|
2123
|
+
#endif
|
|
2124
|
+
|
|
2125
|
+
return false;
|
|
2126
|
+
}
|
|
2127
|
+
|
|
2128
|
+
bool XWindowSystem::canUseARGBImages() const
|
|
2129
|
+
{
|
|
2130
|
+
static bool canUseARGB = false;
|
|
2131
|
+
|
|
2132
|
+
#if JUCE_USE_XSHM
|
|
2133
|
+
static bool checked = false;
|
|
2134
|
+
|
|
2135
|
+
if (! checked)
|
|
2136
|
+
{
|
|
2137
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
2138
|
+
{
|
|
2139
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2140
|
+
XShmSegmentInfo segmentinfo;
|
|
2141
|
+
|
|
2142
|
+
auto testImage = X11Symbols::getInstance()->xShmCreateImage (display,
|
|
2143
|
+
X11Symbols::getInstance()->xDefaultVisual (display, X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
2144
|
+
24, ZPixmap, nullptr, &segmentinfo, 64, 64);
|
|
2145
|
+
|
|
2146
|
+
canUseARGB = testImage != nullptr && testImage->bits_per_pixel == 32;
|
|
2147
|
+
X11Symbols::getInstance()->xDestroyImage (testImage);
|
|
2148
|
+
}
|
|
2149
|
+
else
|
|
2150
|
+
{
|
|
2151
|
+
canUseARGB = false;
|
|
2152
|
+
}
|
|
2153
|
+
|
|
2154
|
+
checked = true;
|
|
2155
|
+
}
|
|
2156
|
+
#endif
|
|
2157
|
+
|
|
2158
|
+
return canUseARGB;
|
|
2159
|
+
}
|
|
2160
|
+
|
|
2161
|
+
bool XWindowSystem::isDarkModeActive() const
|
|
2162
|
+
{
|
|
2163
|
+
const auto themeName = [this]() -> String
|
|
2164
|
+
{
|
|
2165
|
+
if (xSettings != nullptr)
|
|
2166
|
+
{
|
|
2167
|
+
const auto themeNameSetting = xSettings->getSetting (getThemeNameSettingName());
|
|
2168
|
+
|
|
2169
|
+
if (themeNameSetting.isValid()
|
|
2170
|
+
&& themeNameSetting.stringValue.isNotEmpty())
|
|
2171
|
+
{
|
|
2172
|
+
return themeNameSetting.stringValue;
|
|
2173
|
+
}
|
|
2174
|
+
}
|
|
2175
|
+
|
|
2176
|
+
ChildProcess gsettings;
|
|
2177
|
+
|
|
2178
|
+
if (File ("/usr/bin/gsettings").existsAsFile()
|
|
2179
|
+
&& gsettings.start ("/usr/bin/gsettings get org.gnome.desktop.interface gtk-theme", ChildProcess::wantStdOut))
|
|
2180
|
+
{
|
|
2181
|
+
if (gsettings.waitForProcessToFinish (200))
|
|
2182
|
+
return gsettings.readAllProcessOutput();
|
|
2183
|
+
}
|
|
2184
|
+
|
|
2185
|
+
return {};
|
|
2186
|
+
}();
|
|
2187
|
+
|
|
2188
|
+
return (themeName.isNotEmpty()
|
|
2189
|
+
&& (themeName.containsIgnoreCase ("dark") || themeName.containsIgnoreCase ("black")));
|
|
2190
|
+
}
|
|
2191
|
+
|
|
2192
|
+
Image XWindowSystem::createImage (bool isSemiTransparent, int width, int height, bool argb) const
|
|
2193
|
+
{
|
|
2194
|
+
auto visualAndDepth = displayVisuals->getBestVisualForWindow (isSemiTransparent);
|
|
2195
|
+
|
|
2196
|
+
#if JUCE_USE_XSHM
|
|
2197
|
+
return Image (new XBitmapImage (argb ? Image::ARGB : Image::RGB,
|
|
2198
|
+
#else
|
|
2199
|
+
return Image (new XBitmapImage (Image::RGB,
|
|
2200
|
+
#endif
|
|
2201
|
+
(width + 31) & ~31,
|
|
2202
|
+
(height + 31) & ~31,
|
|
2203
|
+
false, (unsigned int) visualAndDepth.depth, visualAndDepth.visual));
|
|
2204
|
+
}
|
|
2205
|
+
|
|
2206
|
+
void XWindowSystem::blitToWindow (::Window windowH, Image image, Rectangle<int> destinationRect, Rectangle<int> totalRect) const
|
|
2207
|
+
{
|
|
2208
|
+
jassert (windowH != 0);
|
|
2209
|
+
|
|
2210
|
+
auto* xbitmap = static_cast<XBitmapImage*> (image.getPixelData());
|
|
2211
|
+
|
|
2212
|
+
xbitmap->blitToWindow (windowH,
|
|
2213
|
+
destinationRect.getX(), destinationRect.getY(),
|
|
2214
|
+
(unsigned int) destinationRect.getWidth(),
|
|
2215
|
+
(unsigned int) destinationRect.getHeight(),
|
|
2216
|
+
destinationRect.getX() - totalRect.getX(), destinationRect.getY() - totalRect.getY());
|
|
2217
|
+
}
|
|
2218
|
+
|
|
2219
|
+
void XWindowSystem::processPendingPaintsForWindow (::Window windowH)
|
|
2220
|
+
{
|
|
2221
|
+
#if JUCE_USE_XSHM
|
|
2222
|
+
if (! XSHMHelpers::isShmAvailable (display))
|
|
2223
|
+
return;
|
|
2224
|
+
|
|
2225
|
+
if (getNumPaintsPendingForWindow (windowH) > 0)
|
|
2226
|
+
{
|
|
2227
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2228
|
+
|
|
2229
|
+
XEvent evt;
|
|
2230
|
+
while (X11Symbols::getInstance()->xCheckTypedWindowEvent (display, windowH, shmCompletionEvent, &evt))
|
|
2231
|
+
removePendingPaintForWindow (windowH);
|
|
2232
|
+
}
|
|
2233
|
+
#endif
|
|
2234
|
+
}
|
|
2235
|
+
|
|
2236
|
+
int XWindowSystem::getNumPaintsPendingForWindow (::Window windowH)
|
|
2237
|
+
{
|
|
2238
|
+
#if JUCE_USE_XSHM
|
|
2239
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
2240
|
+
return shmPaintsPendingMap[windowH];
|
|
2241
|
+
#endif
|
|
2242
|
+
|
|
2243
|
+
return 0;
|
|
2244
|
+
}
|
|
2245
|
+
|
|
2246
|
+
void XWindowSystem::addPendingPaintForWindow (::Window windowH)
|
|
2247
|
+
{
|
|
2248
|
+
#if JUCE_USE_XSHM
|
|
2249
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
2250
|
+
++shmPaintsPendingMap[windowH];
|
|
2251
|
+
#endif
|
|
2252
|
+
}
|
|
2253
|
+
|
|
2254
|
+
void XWindowSystem::removePendingPaintForWindow (::Window windowH)
|
|
2255
|
+
{
|
|
2256
|
+
#if JUCE_USE_XSHM
|
|
2257
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
2258
|
+
--shmPaintsPendingMap[windowH];
|
|
2259
|
+
#endif
|
|
2260
|
+
}
|
|
2261
|
+
|
|
2262
|
+
void XWindowSystem::setScreenSaverEnabled (bool enabled) const
|
|
2263
|
+
{
|
|
2264
|
+
using tXScreenSaverSuspend = void (*) (Display*, Bool);
|
|
2265
|
+
static tXScreenSaverSuspend xScreenSaverSuspend = nullptr;
|
|
2266
|
+
|
|
2267
|
+
if (xScreenSaverSuspend == nullptr)
|
|
2268
|
+
if (void* h = dlopen ("libXss.so.1", RTLD_GLOBAL | RTLD_NOW))
|
|
2269
|
+
xScreenSaverSuspend = (tXScreenSaverSuspend) dlsym (h, "XScreenSaverSuspend");
|
|
2270
|
+
|
|
2271
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2272
|
+
|
|
2273
|
+
NullCheckedInvocation::invoke (xScreenSaverSuspend, display, ! enabled);
|
|
2274
|
+
}
|
|
2275
|
+
|
|
2276
|
+
Point<float> XWindowSystem::getCurrentMousePosition() const
|
|
2277
|
+
{
|
|
2278
|
+
Window root, child;
|
|
2279
|
+
int x, y, winx, winy;
|
|
2280
|
+
unsigned int mask;
|
|
2281
|
+
|
|
2282
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2283
|
+
|
|
2284
|
+
if (X11Symbols::getInstance()->xQueryPointer (display,
|
|
2285
|
+
X11Symbols::getInstance()->xRootWindow (display,
|
|
2286
|
+
X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
2287
|
+
&root, &child,
|
|
2288
|
+
&x, &y, &winx, &winy, &mask) == False)
|
|
2289
|
+
{
|
|
2290
|
+
x = y = -1;
|
|
2291
|
+
}
|
|
2292
|
+
|
|
2293
|
+
return { (float) x, (float) y };
|
|
2294
|
+
}
|
|
2295
|
+
|
|
2296
|
+
void XWindowSystem::setMousePosition (Point<float> pos) const
|
|
2297
|
+
{
|
|
2298
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2299
|
+
|
|
2300
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display,
|
|
2301
|
+
X11Symbols::getInstance()->xDefaultScreen (display));
|
|
2302
|
+
|
|
2303
|
+
X11Symbols::getInstance()->xWarpPointer (display, None, root, 0, 0, 0, 0,
|
|
2304
|
+
roundToInt (pos.getX()), roundToInt (pos.getY()));
|
|
2305
|
+
}
|
|
2306
|
+
|
|
2307
|
+
Cursor XWindowSystem::createCustomMouseCursorInfo (const Image& image, Point<int> hotspot) const
|
|
2308
|
+
{
|
|
2309
|
+
if (display == nullptr)
|
|
2310
|
+
return {};
|
|
2311
|
+
|
|
2312
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2313
|
+
|
|
2314
|
+
auto imageW = (unsigned int) image.getWidth();
|
|
2315
|
+
auto imageH = (unsigned int) image.getHeight();
|
|
2316
|
+
auto hotspotX = hotspot.x;
|
|
2317
|
+
auto hotspotY = hotspot.y;
|
|
2318
|
+
|
|
2319
|
+
#if JUCE_USE_XCURSOR
|
|
2320
|
+
if (auto xcImage = makeDeletedPtr (X11Symbols::getInstance()->xcursorImageCreate ((int) imageW, (int) imageH),
|
|
2321
|
+
[] (XcursorImage* i) { X11Symbols::getInstance()->xcursorImageDestroy (i); }))
|
|
2322
|
+
{
|
|
2323
|
+
xcImage->xhot = (XcursorDim) hotspotX;
|
|
2324
|
+
xcImage->yhot = (XcursorDim) hotspotY;
|
|
2325
|
+
auto* dest = xcImage->pixels;
|
|
2326
|
+
|
|
2327
|
+
for (int y = 0; y < (int) imageH; ++y)
|
|
2328
|
+
for (int x = 0; x < (int) imageW; ++x)
|
|
2329
|
+
*dest++ = image.getPixelAt (x, y).getARGB();
|
|
2330
|
+
|
|
2331
|
+
auto result = X11Symbols::getInstance()->xcursorImageLoadCursor (display, xcImage.get());
|
|
2332
|
+
|
|
2333
|
+
if (result != Cursor{})
|
|
2334
|
+
return result;
|
|
2335
|
+
}
|
|
2336
|
+
#endif
|
|
2337
|
+
|
|
2338
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display,
|
|
2339
|
+
X11Symbols::getInstance()->xDefaultScreen (display));
|
|
2340
|
+
|
|
2341
|
+
unsigned int cursorW, cursorH;
|
|
2342
|
+
if (! X11Symbols::getInstance()->xQueryBestCursor (display, root, imageW, imageH, &cursorW, &cursorH))
|
|
2343
|
+
return {};
|
|
2344
|
+
|
|
2345
|
+
Image im (Image::ARGB, (int) cursorW, (int) cursorH, true);
|
|
2346
|
+
|
|
2347
|
+
{
|
|
2348
|
+
Graphics g (im);
|
|
2349
|
+
|
|
2350
|
+
if (imageW > cursorW || imageH > cursorH)
|
|
2351
|
+
{
|
|
2352
|
+
hotspotX = (hotspotX * (int) cursorW) / (int) imageW;
|
|
2353
|
+
hotspotY = (hotspotY * (int) cursorH) / (int) imageH;
|
|
2354
|
+
|
|
2355
|
+
g.drawImage (image, Rectangle<float> ((float) imageW, (float) imageH),
|
|
2356
|
+
RectanglePlacement::xLeft | RectanglePlacement::yTop | RectanglePlacement::onlyReduceInSize);
|
|
2357
|
+
}
|
|
2358
|
+
else
|
|
2359
|
+
{
|
|
2360
|
+
g.drawImageAt (image, 0, 0);
|
|
2361
|
+
}
|
|
2362
|
+
}
|
|
2363
|
+
|
|
2364
|
+
auto stride = (cursorW + 7) >> 3;
|
|
2365
|
+
HeapBlock<char> maskPlane, sourcePlane;
|
|
2366
|
+
maskPlane.calloc (stride * cursorH);
|
|
2367
|
+
sourcePlane.calloc (stride * cursorH);
|
|
2368
|
+
|
|
2369
|
+
auto msbfirst = (X11Symbols::getInstance()->xBitmapBitOrder (display) == MSBFirst);
|
|
2370
|
+
|
|
2371
|
+
for (auto y = (int) cursorH; --y >= 0;)
|
|
2372
|
+
{
|
|
2373
|
+
for (auto x = (int) cursorW; --x >= 0;)
|
|
2374
|
+
{
|
|
2375
|
+
auto mask = (char) (1 << (msbfirst ? (7 - (x & 7)) : (x & 7)));
|
|
2376
|
+
auto offset = (unsigned int) y * stride + ((unsigned int) x >> 3);
|
|
2377
|
+
|
|
2378
|
+
auto c = im.getPixelAt (x, y);
|
|
2379
|
+
|
|
2380
|
+
if (c.getAlpha() >= 128) maskPlane[offset] |= mask;
|
|
2381
|
+
if (c.getBrightness() >= 0.5f) sourcePlane[offset] |= mask;
|
|
2382
|
+
}
|
|
2383
|
+
}
|
|
2384
|
+
|
|
2385
|
+
auto xFreePixmap = [this] (Pixmap& p) { X11Symbols::getInstance()->xFreePixmap (display, p); };
|
|
2386
|
+
XValueHolder<Pixmap> sourcePixmap (X11Symbols::getInstance()->xCreatePixmapFromBitmapData (display, root, sourcePlane.getData(), cursorW, cursorH, 0xffff, 0, 1), xFreePixmap);
|
|
2387
|
+
XValueHolder<Pixmap> maskPixmap (X11Symbols::getInstance()->xCreatePixmapFromBitmapData (display, root, maskPlane.getData(), cursorW, cursorH, 0xffff, 0, 1), xFreePixmap);
|
|
2388
|
+
|
|
2389
|
+
XColor white, black;
|
|
2390
|
+
black.red = black.green = black.blue = 0;
|
|
2391
|
+
white.red = white.green = white.blue = 0xffff;
|
|
2392
|
+
|
|
2393
|
+
return X11Symbols::getInstance()->xCreatePixmapCursor (display, sourcePixmap.value, maskPixmap.value, &white, &black,
|
|
2394
|
+
(unsigned int) hotspotX, (unsigned int) hotspotY);
|
|
2395
|
+
}
|
|
2396
|
+
|
|
2397
|
+
void XWindowSystem::deleteMouseCursor (Cursor cursorHandle) const
|
|
2398
|
+
{
|
|
2399
|
+
if (cursorHandle != Cursor{} && display != nullptr)
|
|
2400
|
+
{
|
|
2401
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2402
|
+
X11Symbols::getInstance()->xFreeCursor (display, (Cursor) cursorHandle);
|
|
2403
|
+
}
|
|
2404
|
+
}
|
|
2405
|
+
|
|
2406
|
+
static Cursor createDraggingHandCursor()
|
|
2407
|
+
{
|
|
2408
|
+
constexpr unsigned char dragHandData[] = {
|
|
2409
|
+
71,73,70,56,57,97,16,0,16,0,145,2,0,0,0,0,255,255,255,0,0,0,0,0,0,33,249,4,1,0,0,2,0,44,0,0,0,0,16,0,16,0,
|
|
2410
|
+
0,2,52,148,47,0,200,185,16,130,90,12,74,139,107,84,123,39,132,117,151,116,132,146,248,60,209,138,98,22,203,
|
|
2411
|
+
114,34,236,37,52,77,217, 247,154,191,119,110,240,193,128,193,95,163,56,60,234,98,135,2,0,59
|
|
2412
|
+
};
|
|
2413
|
+
|
|
2414
|
+
auto image = ImageFileFormat::loadFrom (dragHandData, (size_t) numElementsInArray (dragHandData));
|
|
2415
|
+
return XWindowSystem::getInstance()->createCustomMouseCursorInfo (std::move (image), { 8, 7 });
|
|
2416
|
+
}
|
|
2417
|
+
|
|
2418
|
+
Cursor XWindowSystem::createStandardMouseCursor (MouseCursor::StandardCursorType type) const
|
|
2419
|
+
{
|
|
2420
|
+
if (display == nullptr)
|
|
2421
|
+
return None;
|
|
2422
|
+
|
|
2423
|
+
unsigned int shape;
|
|
2424
|
+
|
|
2425
|
+
switch (type)
|
|
2426
|
+
{
|
|
2427
|
+
case MouseCursor::NormalCursor:
|
|
2428
|
+
case MouseCursor::ParentCursor: return None; // Use parent cursor
|
|
2429
|
+
case MouseCursor::NoCursor: return XWindowSystem::createCustomMouseCursorInfo (Image (Image::ARGB, 16, 16, true), {});
|
|
2430
|
+
|
|
2431
|
+
case MouseCursor::WaitCursor: shape = XC_watch; break;
|
|
2432
|
+
case MouseCursor::IBeamCursor: shape = XC_xterm; break;
|
|
2433
|
+
case MouseCursor::PointingHandCursor: shape = XC_hand2; break;
|
|
2434
|
+
case MouseCursor::LeftRightResizeCursor: shape = XC_sb_h_double_arrow; break;
|
|
2435
|
+
case MouseCursor::UpDownResizeCursor: shape = XC_sb_v_double_arrow; break;
|
|
2436
|
+
case MouseCursor::UpDownLeftRightResizeCursor: shape = XC_fleur; break;
|
|
2437
|
+
case MouseCursor::TopEdgeResizeCursor: shape = XC_top_side; break;
|
|
2438
|
+
case MouseCursor::BottomEdgeResizeCursor: shape = XC_bottom_side; break;
|
|
2439
|
+
case MouseCursor::LeftEdgeResizeCursor: shape = XC_left_side; break;
|
|
2440
|
+
case MouseCursor::RightEdgeResizeCursor: shape = XC_right_side; break;
|
|
2441
|
+
case MouseCursor::TopLeftCornerResizeCursor: shape = XC_top_left_corner; break;
|
|
2442
|
+
case MouseCursor::TopRightCornerResizeCursor: shape = XC_top_right_corner; break;
|
|
2443
|
+
case MouseCursor::BottomLeftCornerResizeCursor: shape = XC_bottom_left_corner; break;
|
|
2444
|
+
case MouseCursor::BottomRightCornerResizeCursor: shape = XC_bottom_right_corner; break;
|
|
2445
|
+
case MouseCursor::CrosshairCursor: shape = XC_crosshair; break;
|
|
2446
|
+
case MouseCursor::DraggingHandCursor: return createDraggingHandCursor();
|
|
2447
|
+
|
|
2448
|
+
case MouseCursor::CopyingCursor:
|
|
2449
|
+
{
|
|
2450
|
+
constexpr unsigned char copyCursorData[] = {
|
|
2451
|
+
71,73,70,56,57,97,21,0,21,0,145,0,0,0,0,0,255,255,255,0,128,128,255,255,255,33,249,4,1,0,0,3,0,44,0,0,0,0,
|
|
2452
|
+
21,0,21,0,0,2,72,4,134,169,171,16,199,98,11,79,90,71,161,93,56,111,78,133,218,215,137,31,82,154,100,200,
|
|
2453
|
+
86,91,202,142,12,108,212,87,235,174,15,54,214,126,237,226,37,96,59,141,16,37,18,201,142,157,230,204,51,112,
|
|
2454
|
+
252,114,147,74,83,5,50,68,147,208,217,16,71,149,252,124,5,0,59,0,0
|
|
2455
|
+
};
|
|
2456
|
+
|
|
2457
|
+
auto image = ImageFileFormat::loadFrom (copyCursorData, (size_t) numElementsInArray (copyCursorData));
|
|
2458
|
+
return createCustomMouseCursorInfo (std::move (image), { 1, 3 });
|
|
2459
|
+
}
|
|
2460
|
+
|
|
2461
|
+
case MouseCursor::NumStandardCursorTypes:
|
|
2462
|
+
default:
|
|
2463
|
+
{
|
|
2464
|
+
jassertfalse;
|
|
2465
|
+
return None;
|
|
2466
|
+
}
|
|
2467
|
+
}
|
|
2468
|
+
|
|
2469
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2470
|
+
|
|
2471
|
+
return X11Symbols::getInstance()->xCreateFontCursor (display, shape);
|
|
2472
|
+
}
|
|
2473
|
+
|
|
2474
|
+
void XWindowSystem::showCursor (::Window windowH, Cursor cursorHandle) const
|
|
2475
|
+
{
|
|
2476
|
+
jassert (windowH != 0);
|
|
2477
|
+
|
|
2478
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2479
|
+
X11Symbols::getInstance()->xDefineCursor (display, windowH, (Cursor) cursorHandle);
|
|
2480
|
+
}
|
|
2481
|
+
|
|
2482
|
+
bool XWindowSystem::isKeyCurrentlyDown (int keyCode) const
|
|
2483
|
+
{
|
|
2484
|
+
int keysym;
|
|
2485
|
+
|
|
2486
|
+
if (keyCode & Keys::extendedKeyModifier)
|
|
2487
|
+
{
|
|
2488
|
+
keysym = 0xff00 | (keyCode & 0xff);
|
|
2489
|
+
}
|
|
2490
|
+
else
|
|
2491
|
+
{
|
|
2492
|
+
keysym = keyCode;
|
|
2493
|
+
|
|
2494
|
+
if (keysym == (XK_Tab & 0xff)
|
|
2495
|
+
|| keysym == (XK_Return & 0xff)
|
|
2496
|
+
|| keysym == (XK_Escape & 0xff)
|
|
2497
|
+
|| keysym == (XK_BackSpace & 0xff))
|
|
2498
|
+
{
|
|
2499
|
+
keysym |= 0xff00;
|
|
2500
|
+
}
|
|
2501
|
+
}
|
|
2502
|
+
|
|
2503
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2504
|
+
|
|
2505
|
+
auto keycode = X11Symbols::getInstance()->xKeysymToKeycode (display, (KeySym) keysym);
|
|
2506
|
+
auto keybyte = keycode >> 3;
|
|
2507
|
+
auto keybit = (1 << (keycode & 7));
|
|
2508
|
+
|
|
2509
|
+
return (Keys::keyStates [keybyte] & keybit) != 0;
|
|
2510
|
+
}
|
|
2511
|
+
|
|
2512
|
+
ModifierKeys XWindowSystem::getNativeRealtimeModifiers() const
|
|
2513
|
+
{
|
|
2514
|
+
::Window root, child;
|
|
2515
|
+
int x, y, winx, winy;
|
|
2516
|
+
unsigned int mask;
|
|
2517
|
+
int mouseMods = 0, keyboardMods = 0, keyboardClearMods = 0;
|
|
2518
|
+
|
|
2519
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2520
|
+
|
|
2521
|
+
if (X11Symbols::getInstance()->xQueryPointer (display,
|
|
2522
|
+
X11Symbols::getInstance()->xRootWindow (display,
|
|
2523
|
+
X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
2524
|
+
&root, &child, &x, &y, &winx, &winy, &mask) != False)
|
|
2525
|
+
{
|
|
2526
|
+
if ((mask & Button1Mask) != 0) mouseMods |= ModifierKeys::leftButtonModifier;
|
|
2527
|
+
if ((mask & Button2Mask) != 0) mouseMods |= ModifierKeys::middleButtonModifier;
|
|
2528
|
+
if ((mask & Button3Mask) != 0) mouseMods |= ModifierKeys::rightButtonModifier;
|
|
2529
|
+
|
|
2530
|
+
((mask & ShiftMask) != 0 ? keyboardMods : keyboardClearMods) |= ModifierKeys::shiftModifier;
|
|
2531
|
+
((mask & ControlMask) != 0 ? keyboardMods : keyboardClearMods) |= ModifierKeys::ctrlModifier;
|
|
2532
|
+
}
|
|
2533
|
+
|
|
2534
|
+
ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withoutMouseButtons()
|
|
2535
|
+
.withFlags (mouseMods)
|
|
2536
|
+
.withoutFlags (keyboardClearMods)
|
|
2537
|
+
.withFlags (keyboardMods);
|
|
2538
|
+
|
|
2539
|
+
// We are keeping track of the state of modifier keys and mouse buttons with the assumption that
|
|
2540
|
+
// for every mouse down we are going to receive a mouse up etc.
|
|
2541
|
+
//
|
|
2542
|
+
// This assumption is broken when getNativeRealtimeModifiers() is called. If for example we call
|
|
2543
|
+
// this function when the mouse cursor is in another application and the mouse button happens to
|
|
2544
|
+
// be down, then its represented state in currentModifiers may remain down indefinitely, since
|
|
2545
|
+
// we aren't going to receive an event when it's released.
|
|
2546
|
+
//
|
|
2547
|
+
// We mark this state in this variable, and we can restore synchronization when our window
|
|
2548
|
+
// receives an event again.
|
|
2549
|
+
Keys::modifierKeysAreStale = true;
|
|
2550
|
+
|
|
2551
|
+
return ModifierKeys::currentModifiers;
|
|
2552
|
+
}
|
|
2553
|
+
|
|
2554
|
+
static bool hasWorkAreaData (const XWindowSystemUtilities::GetXProperty& prop)
|
|
2555
|
+
{
|
|
2556
|
+
return prop.success
|
|
2557
|
+
&& prop.actualType == XA_CARDINAL
|
|
2558
|
+
&& prop.actualFormat == 32
|
|
2559
|
+
&& prop.numItems == 4
|
|
2560
|
+
&& prop.data != nullptr;
|
|
2561
|
+
}
|
|
2562
|
+
|
|
2563
|
+
static Rectangle<int> getWorkArea (const XWindowSystemUtilities::GetXProperty& prop)
|
|
2564
|
+
{
|
|
2565
|
+
if (hasWorkAreaData (prop))
|
|
2566
|
+
{
|
|
2567
|
+
auto* positionData = prop.data;
|
|
2568
|
+
std::array<long, 4> position;
|
|
2569
|
+
|
|
2570
|
+
for (auto& p : position)
|
|
2571
|
+
{
|
|
2572
|
+
memcpy (&p, positionData, sizeof (long));
|
|
2573
|
+
positionData += sizeof (long);
|
|
2574
|
+
}
|
|
2575
|
+
|
|
2576
|
+
return { (int) position[0], (int) position[1],
|
|
2577
|
+
(int) position[2], (int) position[3] };
|
|
2578
|
+
}
|
|
2579
|
+
|
|
2580
|
+
return {};
|
|
2581
|
+
}
|
|
2582
|
+
|
|
2583
|
+
Array<Displays::Display> XWindowSystem::findDisplays (float masterScale) const
|
|
2584
|
+
{
|
|
2585
|
+
Array<Displays::Display> displays;
|
|
2586
|
+
auto workAreaHints = XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WORKAREA");
|
|
2587
|
+
|
|
2588
|
+
#if JUCE_USE_XRANDR
|
|
2589
|
+
if (workAreaHints != None)
|
|
2590
|
+
{
|
|
2591
|
+
int major_opcode, first_event, first_error;
|
|
2592
|
+
|
|
2593
|
+
if (X11Symbols::getInstance()->xQueryExtension (display, "RANDR", &major_opcode, &first_event, &first_error))
|
|
2594
|
+
{
|
|
2595
|
+
auto numMonitors = X11Symbols::getInstance()->xScreenCount (display);
|
|
2596
|
+
auto mainDisplay = X11Symbols::getInstance()->xRRGetOutputPrimary (display, X11Symbols::getInstance()->xRootWindow (display, 0));
|
|
2597
|
+
|
|
2598
|
+
for (int i = 0; i < numMonitors; ++i)
|
|
2599
|
+
{
|
|
2600
|
+
auto rootWindow = X11Symbols::getInstance()->xRootWindow (display, i);
|
|
2601
|
+
XWindowSystemUtilities::GetXProperty prop (display, rootWindow, workAreaHints, 0, 4, false, XA_CARDINAL);
|
|
2602
|
+
|
|
2603
|
+
if (! hasWorkAreaData (prop))
|
|
2604
|
+
continue;
|
|
2605
|
+
|
|
2606
|
+
if (auto screens = makeDeletedPtr (X11Symbols::getInstance()->xRRGetScreenResources (display, rootWindow),
|
|
2607
|
+
[] (XRRScreenResources* srs) { X11Symbols::getInstance()->xRRFreeScreenResources (srs); }))
|
|
2608
|
+
{
|
|
2609
|
+
for (int j = 0; j < screens->noutput; ++j)
|
|
2610
|
+
{
|
|
2611
|
+
if (screens->outputs[j])
|
|
2612
|
+
{
|
|
2613
|
+
// Xrandr on the raspberry pi fails to determine the main display (mainDisplay == 0)!
|
|
2614
|
+
// Detect this edge case and make the first found display the main display
|
|
2615
|
+
if (! mainDisplay)
|
|
2616
|
+
mainDisplay = screens->outputs[j];
|
|
2617
|
+
|
|
2618
|
+
if (auto output = makeDeletedPtr (X11Symbols::getInstance()->xRRGetOutputInfo (display, screens.get(), screens->outputs[j]),
|
|
2619
|
+
[] (XRROutputInfo* oi) { X11Symbols::getInstance()->xRRFreeOutputInfo (oi); }))
|
|
2620
|
+
{
|
|
2621
|
+
if (output->crtc)
|
|
2622
|
+
{
|
|
2623
|
+
if (auto crtc = makeDeletedPtr (X11Symbols::getInstance()->xRRGetCrtcInfo (display, screens.get(), output->crtc),
|
|
2624
|
+
[] (XRRCrtcInfo* ci) { X11Symbols::getInstance()->xRRFreeCrtcInfo (ci); }))
|
|
2625
|
+
{
|
|
2626
|
+
Displays::Display d;
|
|
2627
|
+
d.totalArea = { crtc->x, crtc->y, (int) crtc->width, (int) crtc->height };
|
|
2628
|
+
d.isMain = (mainDisplay == screens->outputs[j]) && (i == 0);
|
|
2629
|
+
d.dpi = DisplayHelpers::getDisplayDPI (display, 0);
|
|
2630
|
+
|
|
2631
|
+
d.verticalFrequencyHz = [&]() -> std::optional<double>
|
|
2632
|
+
{
|
|
2633
|
+
if (crtc->mode != None)
|
|
2634
|
+
{
|
|
2635
|
+
if (auto it = std::find_if (screens->modes,
|
|
2636
|
+
screens->modes + screens->nmode,
|
|
2637
|
+
[&crtc] (const auto& m) { return m.id == crtc->mode; });
|
|
2638
|
+
it != screens->modes + screens->nmode)
|
|
2639
|
+
{
|
|
2640
|
+
return (double) it->dotClock / ((double) it->hTotal * (double) it->vTotal);
|
|
2641
|
+
}
|
|
2642
|
+
}
|
|
2643
|
+
|
|
2644
|
+
return {};
|
|
2645
|
+
}();
|
|
2646
|
+
|
|
2647
|
+
// The raspberry pi returns a zero sized display, so we need to guard for divide-by-zero
|
|
2648
|
+
if (output->mm_width > 0 && output->mm_height > 0)
|
|
2649
|
+
d.dpi = ((static_cast<double> (crtc->width) * 25.4 * 0.5) / static_cast<double> (output->mm_width))
|
|
2650
|
+
+ ((static_cast<double> (crtc->height) * 25.4 * 0.5) / static_cast<double> (output->mm_height));
|
|
2651
|
+
|
|
2652
|
+
auto scale = DisplayHelpers::getDisplayScale (output->name, d.dpi);
|
|
2653
|
+
scale = (scale <= 0.1 || ! JUCEApplicationBase::isStandaloneApp()) ? 1.0 : scale;
|
|
2654
|
+
|
|
2655
|
+
d.scale = masterScale * scale;
|
|
2656
|
+
|
|
2657
|
+
if (d.isMain)
|
|
2658
|
+
displays.insert (0, d);
|
|
2659
|
+
else
|
|
2660
|
+
displays.add (d);
|
|
2661
|
+
}
|
|
2662
|
+
}
|
|
2663
|
+
}
|
|
2664
|
+
}
|
|
2665
|
+
}
|
|
2666
|
+
}
|
|
2667
|
+
}
|
|
2668
|
+
|
|
2669
|
+
if (! displays.isEmpty() && ! displays.getReference (0).isMain)
|
|
2670
|
+
displays.getReference (0).isMain = true;
|
|
2671
|
+
}
|
|
2672
|
+
}
|
|
2673
|
+
|
|
2674
|
+
if (displays.isEmpty())
|
|
2675
|
+
#endif
|
|
2676
|
+
#if JUCE_USE_XINERAMA
|
|
2677
|
+
{
|
|
2678
|
+
auto screens = DisplayHelpers::xineramaQueryDisplays (display);
|
|
2679
|
+
auto numMonitors = screens.size();
|
|
2680
|
+
|
|
2681
|
+
for (int index = 0; index < numMonitors; ++index)
|
|
2682
|
+
{
|
|
2683
|
+
for (auto j = numMonitors; --j >= 0;)
|
|
2684
|
+
{
|
|
2685
|
+
if (screens[j].screen_number == index)
|
|
2686
|
+
{
|
|
2687
|
+
Displays::Display d;
|
|
2688
|
+
d.totalArea = { screens[j].x_org, screens[j].y_org,
|
|
2689
|
+
screens[j].width, screens[j].height };
|
|
2690
|
+
d.isMain = (index == 0);
|
|
2691
|
+
d.scale = masterScale;
|
|
2692
|
+
d.dpi = DisplayHelpers::getDisplayDPI (display, 0); // (all screens share the same DPI)
|
|
2693
|
+
|
|
2694
|
+
displays.add (d);
|
|
2695
|
+
}
|
|
2696
|
+
}
|
|
2697
|
+
}
|
|
2698
|
+
}
|
|
2699
|
+
|
|
2700
|
+
if (displays.isEmpty())
|
|
2701
|
+
#endif
|
|
2702
|
+
{
|
|
2703
|
+
if (workAreaHints != None)
|
|
2704
|
+
{
|
|
2705
|
+
auto numMonitors = X11Symbols::getInstance()->xScreenCount (display);
|
|
2706
|
+
|
|
2707
|
+
for (int i = 0; i < numMonitors; ++i)
|
|
2708
|
+
{
|
|
2709
|
+
XWindowSystemUtilities::GetXProperty prop (display,
|
|
2710
|
+
X11Symbols::getInstance()->xRootWindow (display, i),
|
|
2711
|
+
workAreaHints, 0, 4, false, XA_CARDINAL);
|
|
2712
|
+
|
|
2713
|
+
auto workArea = getWorkArea (prop);
|
|
2714
|
+
|
|
2715
|
+
if (! workArea.isEmpty())
|
|
2716
|
+
{
|
|
2717
|
+
Displays::Display d;
|
|
2718
|
+
|
|
2719
|
+
d.totalArea = workArea;
|
|
2720
|
+
d.isMain = displays.isEmpty();
|
|
2721
|
+
d.scale = masterScale;
|
|
2722
|
+
d.dpi = DisplayHelpers::getDisplayDPI (display, i);
|
|
2723
|
+
|
|
2724
|
+
displays.add (d);
|
|
2725
|
+
}
|
|
2726
|
+
}
|
|
2727
|
+
}
|
|
2728
|
+
|
|
2729
|
+
if (displays.isEmpty())
|
|
2730
|
+
{
|
|
2731
|
+
Displays::Display d;
|
|
2732
|
+
d.totalArea = { X11Symbols::getInstance()->xDisplayWidth (display, X11Symbols::getInstance()->xDefaultScreen (display)),
|
|
2733
|
+
X11Symbols::getInstance()->xDisplayHeight (display, X11Symbols::getInstance()->xDefaultScreen (display)) };
|
|
2734
|
+
d.isMain = true;
|
|
2735
|
+
d.scale = masterScale;
|
|
2736
|
+
d.dpi = DisplayHelpers::getDisplayDPI (display, 0);
|
|
2737
|
+
|
|
2738
|
+
displays.add (d);
|
|
2739
|
+
}
|
|
2740
|
+
}
|
|
2741
|
+
|
|
2742
|
+
for (auto& d : displays)
|
|
2743
|
+
d.userArea = d.totalArea; // JUCE currently does not support requesting the user area on Linux
|
|
2744
|
+
|
|
2745
|
+
return displays;
|
|
2746
|
+
}
|
|
2747
|
+
|
|
2748
|
+
::Window XWindowSystem::createKeyProxy (::Window windowH)
|
|
2749
|
+
{
|
|
2750
|
+
jassert (windowH != 0);
|
|
2751
|
+
|
|
2752
|
+
XSetWindowAttributes swa;
|
|
2753
|
+
swa.event_mask = KeyPressMask | KeyReleaseMask | FocusChangeMask;
|
|
2754
|
+
|
|
2755
|
+
auto keyProxy = X11Symbols::getInstance()->xCreateWindow (display, windowH,
|
|
2756
|
+
-1, -1, 1, 1, 0, 0,
|
|
2757
|
+
InputOnly, CopyFromParent,
|
|
2758
|
+
CWEventMask,
|
|
2759
|
+
&swa);
|
|
2760
|
+
|
|
2761
|
+
X11Symbols::getInstance()->xMapWindow (display, keyProxy);
|
|
2762
|
+
|
|
2763
|
+
return keyProxy;
|
|
2764
|
+
}
|
|
2765
|
+
|
|
2766
|
+
void XWindowSystem::deleteKeyProxy (::Window keyProxy) const
|
|
2767
|
+
{
|
|
2768
|
+
jassert (keyProxy != 0);
|
|
2769
|
+
|
|
2770
|
+
X11Symbols::getInstance()->xDestroyWindow (display, keyProxy);
|
|
2771
|
+
X11Symbols::getInstance()->xSync (display, false);
|
|
2772
|
+
|
|
2773
|
+
XEvent event;
|
|
2774
|
+
while (X11Symbols::getInstance()->xCheckWindowEvent (display, keyProxy, getAllEventsMask (false), &event) == True)
|
|
2775
|
+
{}
|
|
2776
|
+
}
|
|
2777
|
+
|
|
2778
|
+
bool XWindowSystem::externalDragFileInit (LinuxComponentPeer* peer, const StringArray& files, bool, std::function<void()>&& callback) const
|
|
2779
|
+
{
|
|
2780
|
+
auto& dragState = dragAndDropStateMap[peer];
|
|
2781
|
+
|
|
2782
|
+
if (dragState.isDragging())
|
|
2783
|
+
return false;
|
|
2784
|
+
|
|
2785
|
+
StringArray uriList;
|
|
2786
|
+
|
|
2787
|
+
for (auto& f : files)
|
|
2788
|
+
{
|
|
2789
|
+
if (f.matchesWildcard ("?*://*", false))
|
|
2790
|
+
uriList.add (f);
|
|
2791
|
+
else
|
|
2792
|
+
uriList.add ("file://" + f);
|
|
2793
|
+
}
|
|
2794
|
+
|
|
2795
|
+
return dragState.externalDragInit ((::Window) peer->getNativeHandle(), false, uriList.joinIntoString ("\r\n"), std::move (callback));
|
|
2796
|
+
}
|
|
2797
|
+
|
|
2798
|
+
bool XWindowSystem::externalDragTextInit (LinuxComponentPeer* peer, const String& text, std::function<void()>&& callback) const
|
|
2799
|
+
{
|
|
2800
|
+
auto& dragState = dragAndDropStateMap[peer];
|
|
2801
|
+
|
|
2802
|
+
if (dragState.isDragging())
|
|
2803
|
+
return false;
|
|
2804
|
+
|
|
2805
|
+
return dragState.externalDragInit ((::Window) peer->getNativeHandle(), true, text, std::move (callback));
|
|
2806
|
+
}
|
|
2807
|
+
|
|
2808
|
+
void XWindowSystem::copyTextToClipboard (const String& clipText)
|
|
2809
|
+
{
|
|
2810
|
+
localClipboardContent = clipText;
|
|
2811
|
+
|
|
2812
|
+
X11Symbols::getInstance()->xSetSelectionOwner (display, XA_PRIMARY, juce_messageWindowHandle, CurrentTime);
|
|
2813
|
+
X11Symbols::getInstance()->xSetSelectionOwner (display, atoms.clipboard, juce_messageWindowHandle, CurrentTime);
|
|
2814
|
+
}
|
|
2815
|
+
|
|
2816
|
+
String XWindowSystem::getTextFromClipboard() const
|
|
2817
|
+
{
|
|
2818
|
+
/* 1) try to read from the "CLIPBOARD" selection first (the "high
|
|
2819
|
+
level" clipboard that is supposed to be filled by ctrl-C
|
|
2820
|
+
etc). When a clipboard manager is running, the content of this
|
|
2821
|
+
selection is preserved even when the original selection owner
|
|
2822
|
+
exits.
|
|
2823
|
+
|
|
2824
|
+
2) and then try to read from "PRIMARY" selection (the "legacy" selection
|
|
2825
|
+
filled by good old x11 apps such as xterm)
|
|
2826
|
+
*/
|
|
2827
|
+
|
|
2828
|
+
auto getContentForSelection = [this] (Atom selectionAtom) -> String
|
|
2829
|
+
{
|
|
2830
|
+
auto selectionOwner = X11Symbols::getInstance()->xGetSelectionOwner (display, selectionAtom);
|
|
2831
|
+
|
|
2832
|
+
if (selectionOwner == None)
|
|
2833
|
+
return {};
|
|
2834
|
+
|
|
2835
|
+
if (selectionOwner == juce_messageWindowHandle)
|
|
2836
|
+
return localClipboardContent;
|
|
2837
|
+
|
|
2838
|
+
String content;
|
|
2839
|
+
|
|
2840
|
+
if (! ClipboardHelpers::requestSelectionContent (display, content, selectionAtom, atoms.utf8String))
|
|
2841
|
+
ClipboardHelpers::requestSelectionContent (display, content, selectionAtom, XA_STRING);
|
|
2842
|
+
|
|
2843
|
+
return content;
|
|
2844
|
+
};
|
|
2845
|
+
|
|
2846
|
+
auto content = getContentForSelection (atoms.clipboard);
|
|
2847
|
+
|
|
2848
|
+
if (content.isEmpty())
|
|
2849
|
+
content = getContentForSelection (XA_PRIMARY);
|
|
2850
|
+
|
|
2851
|
+
return content;
|
|
2852
|
+
}
|
|
2853
|
+
|
|
2854
|
+
//==============================================================================
|
|
2855
|
+
::Window XWindowSystem::findTopLevelWindowOf (::Window w) const
|
|
2856
|
+
{
|
|
2857
|
+
if (w == 0)
|
|
2858
|
+
return 0;
|
|
2859
|
+
|
|
2860
|
+
Window* windowList = nullptr;
|
|
2861
|
+
uint32 windowListSize = 0;
|
|
2862
|
+
Window parent, root;
|
|
2863
|
+
|
|
2864
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2865
|
+
const auto result = X11Symbols::getInstance()->xQueryTree (display, w, &root, &parent, &windowList, &windowListSize);
|
|
2866
|
+
const auto deleter = makeXFreePtr (windowList);
|
|
2867
|
+
|
|
2868
|
+
if (result == 0)
|
|
2869
|
+
return 0;
|
|
2870
|
+
|
|
2871
|
+
if (parent == root)
|
|
2872
|
+
return w;
|
|
2873
|
+
|
|
2874
|
+
return findTopLevelWindowOf (parent);
|
|
2875
|
+
}
|
|
2876
|
+
|
|
2877
|
+
bool XWindowSystem::isParentWindowOf (::Window windowH, ::Window possibleChild) const
|
|
2878
|
+
{
|
|
2879
|
+
if (windowH == 0 || possibleChild == 0)
|
|
2880
|
+
return false;
|
|
2881
|
+
|
|
2882
|
+
if (possibleChild == windowH)
|
|
2883
|
+
return true;
|
|
2884
|
+
|
|
2885
|
+
Window* windowList = nullptr;
|
|
2886
|
+
uint32 windowListSize = 0;
|
|
2887
|
+
Window parent, root;
|
|
2888
|
+
|
|
2889
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2890
|
+
const auto result = X11Symbols::getInstance()->xQueryTree (display, possibleChild, &root, &parent, &windowList, &windowListSize);
|
|
2891
|
+
const auto deleter = makeXFreePtr (windowList);
|
|
2892
|
+
|
|
2893
|
+
if (result == 0 || parent == root)
|
|
2894
|
+
return false;
|
|
2895
|
+
|
|
2896
|
+
return isParentWindowOf (windowH, parent);
|
|
2897
|
+
}
|
|
2898
|
+
|
|
2899
|
+
bool XWindowSystem::isFrontWindow (::Window windowH) const
|
|
2900
|
+
{
|
|
2901
|
+
jassert (windowH != 0);
|
|
2902
|
+
|
|
2903
|
+
Window* windowList = nullptr;
|
|
2904
|
+
uint32 windowListSize = 0;
|
|
2905
|
+
|
|
2906
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2907
|
+
Window parent;
|
|
2908
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
2909
|
+
|
|
2910
|
+
const auto queryResult = X11Symbols::getInstance()->xQueryTree (display, root, &root, &parent, &windowList, &windowListSize);
|
|
2911
|
+
const auto deleter = makeXFreePtr (windowList);
|
|
2912
|
+
|
|
2913
|
+
if (queryResult == 0)
|
|
2914
|
+
return false;
|
|
2915
|
+
|
|
2916
|
+
for (int i = (int) windowListSize; --i >= 0;)
|
|
2917
|
+
{
|
|
2918
|
+
if (auto* peer = dynamic_cast<LinuxComponentPeer*> (getPeerFor (windowList[i])))
|
|
2919
|
+
return peer == dynamic_cast<LinuxComponentPeer*> (getPeerFor (windowH));
|
|
2920
|
+
}
|
|
2921
|
+
|
|
2922
|
+
return false;
|
|
2923
|
+
}
|
|
2924
|
+
|
|
2925
|
+
void XWindowSystem::xchangeProperty (::Window windowH, Atom property, Atom type, int format, const void* data, int numElements) const
|
|
2926
|
+
{
|
|
2927
|
+
jassert (windowH != 0);
|
|
2928
|
+
|
|
2929
|
+
X11Symbols::getInstance()->xChangeProperty (display, windowH, property, type, format, PropModeReplace, (const unsigned char*) data, numElements);
|
|
2930
|
+
}
|
|
2931
|
+
|
|
2932
|
+
void XWindowSystem::removeWindowDecorations (::Window windowH) const
|
|
2933
|
+
{
|
|
2934
|
+
jassert (windowH != 0);
|
|
2935
|
+
|
|
2936
|
+
auto hints = XWindowSystemUtilities::Atoms::getIfExists (display, "_MOTIF_WM_HINTS");
|
|
2937
|
+
|
|
2938
|
+
if (hints != None)
|
|
2939
|
+
{
|
|
2940
|
+
MotifWmHints motifHints;
|
|
2941
|
+
zerostruct (motifHints);
|
|
2942
|
+
|
|
2943
|
+
motifHints.flags = 2; /* MWM_HINTS_DECORATIONS */
|
|
2944
|
+
motifHints.decorations = 0;
|
|
2945
|
+
|
|
2946
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2947
|
+
xchangeProperty (windowH, hints, hints, 32, &motifHints, 4);
|
|
2948
|
+
}
|
|
2949
|
+
|
|
2950
|
+
hints = XWindowSystemUtilities::Atoms::getIfExists (display, "_WIN_HINTS");
|
|
2951
|
+
|
|
2952
|
+
if (hints != None)
|
|
2953
|
+
{
|
|
2954
|
+
long gnomeHints = 0;
|
|
2955
|
+
|
|
2956
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2957
|
+
xchangeProperty (windowH, hints, hints, 32, &gnomeHints, 1);
|
|
2958
|
+
}
|
|
2959
|
+
|
|
2960
|
+
hints = XWindowSystemUtilities::Atoms::getIfExists (display, "KWM_WIN_DECORATION");
|
|
2961
|
+
|
|
2962
|
+
if (hints != None)
|
|
2963
|
+
{
|
|
2964
|
+
long kwmHints = 2; /*KDE_tinyDecoration*/
|
|
2965
|
+
|
|
2966
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2967
|
+
xchangeProperty (windowH, hints, hints, 32, &kwmHints, 1);
|
|
2968
|
+
}
|
|
2969
|
+
|
|
2970
|
+
hints = XWindowSystemUtilities::Atoms::getIfExists (display, "_KDE_NET_WM_WINDOW_TYPE_OVERRIDE");
|
|
2971
|
+
|
|
2972
|
+
if (hints != None)
|
|
2973
|
+
{
|
|
2974
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2975
|
+
xchangeProperty (windowH, atoms.windowType, XA_ATOM, 32, &hints, 1);
|
|
2976
|
+
}
|
|
2977
|
+
}
|
|
2978
|
+
|
|
2979
|
+
static void addAtomIfExists (bool condition, const char* key, ::Display* display, std::vector<Atom>& atoms)
|
|
2980
|
+
{
|
|
2981
|
+
if (condition)
|
|
2982
|
+
{
|
|
2983
|
+
auto atom = XWindowSystemUtilities::Atoms::getIfExists (display, key);
|
|
2984
|
+
|
|
2985
|
+
if (atom != None)
|
|
2986
|
+
atoms.push_back (atom);
|
|
2987
|
+
}
|
|
2988
|
+
}
|
|
2989
|
+
|
|
2990
|
+
void XWindowSystem::addWindowButtons (::Window windowH, int styleFlags) const
|
|
2991
|
+
{
|
|
2992
|
+
jassert (windowH != 0);
|
|
2993
|
+
|
|
2994
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
2995
|
+
auto motifAtom = XWindowSystemUtilities::Atoms::getIfExists (display, "_MOTIF_WM_HINTS");
|
|
2996
|
+
|
|
2997
|
+
if (motifAtom != None)
|
|
2998
|
+
{
|
|
2999
|
+
MotifWmHints motifHints;
|
|
3000
|
+
zerostruct (motifHints);
|
|
3001
|
+
|
|
3002
|
+
motifHints.flags = 1 | 2; /* MWM_HINTS_FUNCTIONS | MWM_HINTS_DECORATIONS */
|
|
3003
|
+
motifHints.decorations = 2 /* MWM_DECOR_BORDER */ | 8 /* MWM_DECOR_TITLE */ | 16; /* MWM_DECOR_MENU */
|
|
3004
|
+
|
|
3005
|
+
motifHints.functions = 4 /* MWM_FUNC_MOVE */;
|
|
3006
|
+
|
|
3007
|
+
if ((styleFlags & ComponentPeer::windowHasCloseButton) != 0)
|
|
3008
|
+
motifHints.functions |= 32; /* MWM_FUNC_CLOSE */
|
|
3009
|
+
|
|
3010
|
+
if ((styleFlags & ComponentPeer::windowHasMinimiseButton) != 0)
|
|
3011
|
+
{
|
|
3012
|
+
motifHints.functions |= 8; /* MWM_FUNC_MINIMIZE */
|
|
3013
|
+
motifHints.decorations |= 0x20; /* MWM_DECOR_MINIMIZE */
|
|
3014
|
+
}
|
|
3015
|
+
|
|
3016
|
+
if ((styleFlags & ComponentPeer::windowHasMaximiseButton) != 0)
|
|
3017
|
+
{
|
|
3018
|
+
motifHints.functions |= 0x10; /* MWM_FUNC_MAXIMIZE */
|
|
3019
|
+
motifHints.decorations |= 0x40; /* MWM_DECOR_MAXIMIZE */
|
|
3020
|
+
}
|
|
3021
|
+
|
|
3022
|
+
if ((styleFlags & ComponentPeer::windowIsResizable) != 0)
|
|
3023
|
+
{
|
|
3024
|
+
motifHints.functions |= 2; /* MWM_FUNC_RESIZE */
|
|
3025
|
+
motifHints.decorations |= 0x4; /* MWM_DECOR_RESIZEH */
|
|
3026
|
+
}
|
|
3027
|
+
|
|
3028
|
+
xchangeProperty (windowH, motifAtom, motifAtom, 32, &motifHints, 5);
|
|
3029
|
+
}
|
|
3030
|
+
|
|
3031
|
+
auto actionsAtom = XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WM_ALLOWED_ACTIONS");
|
|
3032
|
+
|
|
3033
|
+
if (actionsAtom != None)
|
|
3034
|
+
{
|
|
3035
|
+
std::vector<Atom> netHints;
|
|
3036
|
+
|
|
3037
|
+
addAtomIfExists ((styleFlags & ComponentPeer::windowIsResizable) != 0, "_NET_WM_ACTION_RESIZE", display, netHints);
|
|
3038
|
+
addAtomIfExists ((styleFlags & ComponentPeer::windowHasMaximiseButton) != 0, "_NET_WM_ACTION_FULLSCREEN", display, netHints);
|
|
3039
|
+
addAtomIfExists ((styleFlags & ComponentPeer::windowHasMinimiseButton) != 0, "_NET_WM_ACTION_MINIMIZE", display, netHints);
|
|
3040
|
+
addAtomIfExists ((styleFlags & ComponentPeer::windowHasCloseButton) != 0, "_NET_WM_ACTION_CLOSE", display, netHints);
|
|
3041
|
+
|
|
3042
|
+
auto numHints = (int) netHints.size();
|
|
3043
|
+
|
|
3044
|
+
if (numHints > 0)
|
|
3045
|
+
xchangeProperty (windowH, actionsAtom, XA_ATOM, 32, netHints.data(), numHints);
|
|
3046
|
+
}
|
|
3047
|
+
}
|
|
3048
|
+
|
|
3049
|
+
void XWindowSystem::setWindowType (::Window windowH, int styleFlags) const
|
|
3050
|
+
{
|
|
3051
|
+
jassert (windowH != 0);
|
|
3052
|
+
|
|
3053
|
+
if (atoms.windowType != None)
|
|
3054
|
+
{
|
|
3055
|
+
auto hint = (styleFlags & ComponentPeer::windowIsTemporary) != 0
|
|
3056
|
+
|| ((styleFlags & ComponentPeer::windowHasDropShadow) == 0 && Desktop::canUseSemiTransparentWindows())
|
|
3057
|
+
? XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WM_WINDOW_TYPE_COMBO")
|
|
3058
|
+
: XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_WM_WINDOW_TYPE_NORMAL");
|
|
3059
|
+
|
|
3060
|
+
if (hint != None)
|
|
3061
|
+
xchangeProperty (windowH, atoms.windowType, XA_ATOM, 32, &hint, 1);
|
|
3062
|
+
}
|
|
3063
|
+
|
|
3064
|
+
if (atoms.windowState != None)
|
|
3065
|
+
{
|
|
3066
|
+
std::vector<Atom> netStateHints;
|
|
3067
|
+
|
|
3068
|
+
addAtomIfExists ((styleFlags & ComponentPeer::windowAppearsOnTaskbar) == 0, "_NET_WM_STATE_SKIP_TASKBAR", display, netStateHints);
|
|
3069
|
+
addAtomIfExists (getPeerFor (windowH)->getComponent().isAlwaysOnTop(), "_NET_WM_STATE_ABOVE", display, netStateHints);
|
|
3070
|
+
|
|
3071
|
+
auto numHints = (int) netStateHints.size();
|
|
3072
|
+
|
|
3073
|
+
if (numHints > 0)
|
|
3074
|
+
xchangeProperty (windowH, atoms.windowState, XA_ATOM, 32, netStateHints.data(), numHints);
|
|
3075
|
+
}
|
|
3076
|
+
}
|
|
3077
|
+
|
|
3078
|
+
void XWindowSystem::initialisePointerMap()
|
|
3079
|
+
{
|
|
3080
|
+
auto numButtons = X11Symbols::getInstance()->xGetPointerMapping (display, nullptr, 0);
|
|
3081
|
+
pointerMap[2] = pointerMap[3] = pointerMap[4] = Keys::NoButton;
|
|
3082
|
+
|
|
3083
|
+
if (numButtons == 2)
|
|
3084
|
+
{
|
|
3085
|
+
pointerMap[0] = Keys::LeftButton;
|
|
3086
|
+
pointerMap[1] = Keys::RightButton;
|
|
3087
|
+
}
|
|
3088
|
+
else if (numButtons >= 3)
|
|
3089
|
+
{
|
|
3090
|
+
pointerMap[0] = Keys::LeftButton;
|
|
3091
|
+
pointerMap[1] = Keys::MiddleButton;
|
|
3092
|
+
pointerMap[2] = Keys::RightButton;
|
|
3093
|
+
|
|
3094
|
+
if (numButtons >= 5)
|
|
3095
|
+
{
|
|
3096
|
+
pointerMap[3] = Keys::WheelUp;
|
|
3097
|
+
pointerMap[4] = Keys::WheelDown;
|
|
3098
|
+
}
|
|
3099
|
+
}
|
|
3100
|
+
}
|
|
3101
|
+
|
|
3102
|
+
void XWindowSystem::deleteIconPixmaps (::Window windowH) const
|
|
3103
|
+
{
|
|
3104
|
+
jassert (windowH != 0);
|
|
3105
|
+
|
|
3106
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3107
|
+
|
|
3108
|
+
if (auto wmHints = makeXFreePtr (X11Symbols::getInstance()->xGetWMHints (display, windowH)))
|
|
3109
|
+
{
|
|
3110
|
+
if ((wmHints->flags & IconPixmapHint) != 0)
|
|
3111
|
+
{
|
|
3112
|
+
wmHints->flags &= ~IconPixmapHint;
|
|
3113
|
+
X11Symbols::getInstance()->xFreePixmap (display, wmHints->icon_pixmap);
|
|
3114
|
+
}
|
|
3115
|
+
|
|
3116
|
+
if ((wmHints->flags & IconMaskHint) != 0)
|
|
3117
|
+
{
|
|
3118
|
+
wmHints->flags &= ~IconMaskHint;
|
|
3119
|
+
X11Symbols::getInstance()->xFreePixmap (display, wmHints->icon_mask);
|
|
3120
|
+
}
|
|
3121
|
+
|
|
3122
|
+
X11Symbols::getInstance()->xSetWMHints (display, windowH, wmHints.get());
|
|
3123
|
+
}
|
|
3124
|
+
}
|
|
3125
|
+
|
|
3126
|
+
// Alt and Num lock are not defined by standard X modifier constants: check what they're mapped to
|
|
3127
|
+
void XWindowSystem::updateModifierMappings() const
|
|
3128
|
+
{
|
|
3129
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3130
|
+
auto altLeftCode = X11Symbols::getInstance()->xKeysymToKeycode (display, XK_Alt_L);
|
|
3131
|
+
auto numLockCode = X11Symbols::getInstance()->xKeysymToKeycode (display, XK_Num_Lock);
|
|
3132
|
+
|
|
3133
|
+
Keys::AltMask = 0;
|
|
3134
|
+
Keys::NumLockMask = 0;
|
|
3135
|
+
|
|
3136
|
+
if (auto mapping = makeDeletedPtr (X11Symbols::getInstance()->xGetModifierMapping (display),
|
|
3137
|
+
[] (XModifierKeymap* mk) { X11Symbols::getInstance()->xFreeModifiermap (mk); }))
|
|
3138
|
+
{
|
|
3139
|
+
for (int modifierIdx = 0; modifierIdx < 8; ++modifierIdx)
|
|
3140
|
+
{
|
|
3141
|
+
for (int keyIndex = 0; keyIndex < mapping->max_keypermod; ++keyIndex)
|
|
3142
|
+
{
|
|
3143
|
+
auto key = mapping->modifiermap[(modifierIdx * mapping->max_keypermod) + keyIndex];
|
|
3144
|
+
|
|
3145
|
+
if (key == altLeftCode)
|
|
3146
|
+
Keys::AltMask = 1 << modifierIdx;
|
|
3147
|
+
else if (key == numLockCode)
|
|
3148
|
+
Keys::NumLockMask = 1 << modifierIdx;
|
|
3149
|
+
}
|
|
3150
|
+
}
|
|
3151
|
+
}
|
|
3152
|
+
}
|
|
3153
|
+
|
|
3154
|
+
long XWindowSystem::getUserTime (::Window windowH) const
|
|
3155
|
+
{
|
|
3156
|
+
jassert (windowH != 0);
|
|
3157
|
+
|
|
3158
|
+
XWindowSystemUtilities::GetXProperty prop (display, windowH, atoms.userTime, 0, 65536, false, XA_CARDINAL);
|
|
3159
|
+
|
|
3160
|
+
if (! prop.success)
|
|
3161
|
+
return 0;
|
|
3162
|
+
|
|
3163
|
+
long result = 0;
|
|
3164
|
+
std::memcpy (&result, prop.data, sizeof (long));
|
|
3165
|
+
|
|
3166
|
+
return result;
|
|
3167
|
+
}
|
|
3168
|
+
|
|
3169
|
+
void XWindowSystem::initialiseXSettings()
|
|
3170
|
+
{
|
|
3171
|
+
xSettings = XWindowSystemUtilities::XSettings::createXSettings (display);
|
|
3172
|
+
|
|
3173
|
+
if (xSettings != nullptr)
|
|
3174
|
+
X11Symbols::getInstance()->xSelectInput (display,
|
|
3175
|
+
xSettings->getSettingsWindow(),
|
|
3176
|
+
StructureNotifyMask | PropertyChangeMask);
|
|
3177
|
+
}
|
|
3178
|
+
|
|
3179
|
+
XWindowSystem::DisplayVisuals::DisplayVisuals (::Display* xDisplay)
|
|
3180
|
+
{
|
|
3181
|
+
auto findVisualWithDepthOrNull = [&] (int desiredDepth) -> Visual*
|
|
3182
|
+
{
|
|
3183
|
+
int matchedDepth = 0;
|
|
3184
|
+
auto* visual = Visuals::findVisualFormat (xDisplay, desiredDepth, matchedDepth);
|
|
3185
|
+
|
|
3186
|
+
if (desiredDepth == matchedDepth)
|
|
3187
|
+
return visual;
|
|
3188
|
+
|
|
3189
|
+
return nullptr;
|
|
3190
|
+
};
|
|
3191
|
+
|
|
3192
|
+
visual16Bit = findVisualWithDepthOrNull (16);
|
|
3193
|
+
visual24Bit = findVisualWithDepthOrNull (24);
|
|
3194
|
+
visual32Bit = findVisualWithDepthOrNull (32);
|
|
3195
|
+
}
|
|
3196
|
+
|
|
3197
|
+
XWindowSystem::VisualAndDepth XWindowSystem::DisplayVisuals::getBestVisualForWindow (bool isSemiTransparent) const
|
|
3198
|
+
{
|
|
3199
|
+
if (isSemiTransparent && visual32Bit != nullptr)
|
|
3200
|
+
return { visual32Bit, 32 };
|
|
3201
|
+
|
|
3202
|
+
if (visual24Bit != nullptr)
|
|
3203
|
+
return { visual24Bit, 24 };
|
|
3204
|
+
|
|
3205
|
+
if (visual32Bit != nullptr)
|
|
3206
|
+
return { visual32Bit, 32 };
|
|
3207
|
+
|
|
3208
|
+
// No visual available!
|
|
3209
|
+
jassert (visual16Bit != nullptr);
|
|
3210
|
+
|
|
3211
|
+
return { visual16Bit, 16 };
|
|
3212
|
+
}
|
|
3213
|
+
|
|
3214
|
+
bool XWindowSystem::DisplayVisuals::isValid() const noexcept
|
|
3215
|
+
{
|
|
3216
|
+
return (visual32Bit != nullptr || visual24Bit != nullptr || visual16Bit != nullptr);
|
|
3217
|
+
}
|
|
3218
|
+
|
|
3219
|
+
//==============================================================================
|
|
3220
|
+
bool XWindowSystem::initialiseXDisplay()
|
|
3221
|
+
{
|
|
3222
|
+
jassert (display == nullptr);
|
|
3223
|
+
|
|
3224
|
+
String displayName (getenv ("DISPLAY"));
|
|
3225
|
+
|
|
3226
|
+
if (displayName.isEmpty())
|
|
3227
|
+
displayName = ":0.0";
|
|
3228
|
+
|
|
3229
|
+
// it seems that on some systems XOpenDisplay will occasionally
|
|
3230
|
+
// fail the first time, but succeed on a second attempt..
|
|
3231
|
+
for (int retries = 2; --retries >= 0;)
|
|
3232
|
+
{
|
|
3233
|
+
display = X11Symbols::getInstance()->xOpenDisplay (displayName.toUTF8());
|
|
3234
|
+
|
|
3235
|
+
if (display != nullptr)
|
|
3236
|
+
break;
|
|
3237
|
+
}
|
|
3238
|
+
|
|
3239
|
+
// No X Server running
|
|
3240
|
+
if (display == nullptr)
|
|
3241
|
+
return false;
|
|
3242
|
+
|
|
3243
|
+
#if JUCE_DEBUG_XERRORS_SYNCHRONOUSLY
|
|
3244
|
+
X11Symbols::getInstance()->xSynchronize (display, True);
|
|
3245
|
+
#endif
|
|
3246
|
+
|
|
3247
|
+
// Create a context to store user data associated with Windows we create
|
|
3248
|
+
windowHandleXContext = (XContext) X11Symbols::getInstance()->xrmUniqueQuark();
|
|
3249
|
+
|
|
3250
|
+
// Create our message window (this will never be mapped)
|
|
3251
|
+
auto screen = X11Symbols::getInstance()->xDefaultScreen (display);
|
|
3252
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, screen);
|
|
3253
|
+
X11Symbols::getInstance()->xSelectInput (display, root, SubstructureNotifyMask);
|
|
3254
|
+
|
|
3255
|
+
// We're only interested in client messages for this window, which are always sent
|
|
3256
|
+
XSetWindowAttributes swa;
|
|
3257
|
+
swa.event_mask = NoEventMask;
|
|
3258
|
+
juce_messageWindowHandle = X11Symbols::getInstance()->xCreateWindow (display, root,
|
|
3259
|
+
0, 0, 1, 1, 0, 0, InputOnly,
|
|
3260
|
+
X11Symbols::getInstance()->xDefaultVisual (display, screen),
|
|
3261
|
+
CWEventMask, &swa);
|
|
3262
|
+
|
|
3263
|
+
X11Symbols::getInstance()->xSync (display, False);
|
|
3264
|
+
|
|
3265
|
+
atoms = XWindowSystemUtilities::Atoms (display);
|
|
3266
|
+
|
|
3267
|
+
initialisePointerMap();
|
|
3268
|
+
updateModifierMappings();
|
|
3269
|
+
initialiseXSettings();
|
|
3270
|
+
|
|
3271
|
+
#if JUCE_USE_XSHM
|
|
3272
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
3273
|
+
shmCompletionEvent = X11Symbols::getInstance()->xShmGetEventBase (display) + ShmCompletion;
|
|
3274
|
+
#endif
|
|
3275
|
+
|
|
3276
|
+
displayVisuals = std::make_unique<DisplayVisuals> (display);
|
|
3277
|
+
|
|
3278
|
+
if (! displayVisuals->isValid())
|
|
3279
|
+
{
|
|
3280
|
+
Logger::outputDebugString ("ERROR: System doesn't support 32, 24 or 16 bit RGB display.\n");
|
|
3281
|
+
return false;
|
|
3282
|
+
}
|
|
3283
|
+
|
|
3284
|
+
// Setup input event handler
|
|
3285
|
+
LinuxEventLoop::registerFdCallback (X11Symbols::getInstance()->xConnectionNumber (display),
|
|
3286
|
+
[this] (int)
|
|
3287
|
+
{
|
|
3288
|
+
do
|
|
3289
|
+
{
|
|
3290
|
+
XEvent evt;
|
|
3291
|
+
|
|
3292
|
+
{
|
|
3293
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3294
|
+
|
|
3295
|
+
if (! X11Symbols::getInstance()->xPending (display))
|
|
3296
|
+
return;
|
|
3297
|
+
|
|
3298
|
+
X11Symbols::getInstance()->xNextEvent (display, &evt);
|
|
3299
|
+
}
|
|
3300
|
+
|
|
3301
|
+
if (evt.type == SelectionRequest && evt.xany.window == juce_messageWindowHandle)
|
|
3302
|
+
{
|
|
3303
|
+
ClipboardHelpers::handleSelection (evt.xselectionrequest);
|
|
3304
|
+
}
|
|
3305
|
+
else if (evt.xany.window != juce_messageWindowHandle)
|
|
3306
|
+
{
|
|
3307
|
+
windowMessageReceive (evt);
|
|
3308
|
+
}
|
|
3309
|
+
|
|
3310
|
+
} while (display != nullptr);
|
|
3311
|
+
});
|
|
3312
|
+
|
|
3313
|
+
return true;
|
|
3314
|
+
}
|
|
3315
|
+
|
|
3316
|
+
void XWindowSystem::destroyXDisplay()
|
|
3317
|
+
{
|
|
3318
|
+
if (xIsAvailable)
|
|
3319
|
+
{
|
|
3320
|
+
jassert (display != nullptr);
|
|
3321
|
+
|
|
3322
|
+
{
|
|
3323
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3324
|
+
|
|
3325
|
+
X11Symbols::getInstance()->xDestroyWindow (display, juce_messageWindowHandle);
|
|
3326
|
+
juce_messageWindowHandle = 0;
|
|
3327
|
+
X11Symbols::getInstance()->xSync (display, True);
|
|
3328
|
+
}
|
|
3329
|
+
|
|
3330
|
+
LinuxEventLoop::unregisterFdCallback (X11Symbols::getInstance()->xConnectionNumber (display));
|
|
3331
|
+
|
|
3332
|
+
{
|
|
3333
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3334
|
+
X11Symbols::getInstance()->xCloseDisplay (display);
|
|
3335
|
+
display = nullptr;
|
|
3336
|
+
displayVisuals = nullptr;
|
|
3337
|
+
}
|
|
3338
|
+
}
|
|
3339
|
+
}
|
|
3340
|
+
|
|
3341
|
+
//==============================================================================
|
|
3342
|
+
::Window juce_createKeyProxyWindow (ComponentPeer* peer);
|
|
3343
|
+
::Window juce_createKeyProxyWindow (ComponentPeer* peer)
|
|
3344
|
+
{
|
|
3345
|
+
return XWindowSystem::getInstance()->createKeyProxy ((::Window) peer->getNativeHandle());
|
|
3346
|
+
}
|
|
3347
|
+
|
|
3348
|
+
void juce_deleteKeyProxyWindow (::Window keyProxy);
|
|
3349
|
+
void juce_deleteKeyProxyWindow (::Window keyProxy)
|
|
3350
|
+
{
|
|
3351
|
+
XWindowSystem::getInstance()->deleteKeyProxy (keyProxy);
|
|
3352
|
+
}
|
|
3353
|
+
|
|
3354
|
+
//==============================================================================
|
|
3355
|
+
template <typename EventType>
|
|
3356
|
+
static Point<float> getLogicalMousePos (const EventType& e, double scaleFactor) noexcept
|
|
3357
|
+
{
|
|
3358
|
+
return Point<float> ((float) e.x, (float) e.y) / scaleFactor;
|
|
3359
|
+
}
|
|
3360
|
+
|
|
3361
|
+
static int64 getEventTime (::Time t)
|
|
3362
|
+
{
|
|
3363
|
+
static int64 eventTimeOffset = 0x12345678;
|
|
3364
|
+
auto thisMessageTime = (int64) t;
|
|
3365
|
+
|
|
3366
|
+
if (eventTimeOffset == 0x12345678)
|
|
3367
|
+
eventTimeOffset = Time::currentTimeMillis() - thisMessageTime;
|
|
3368
|
+
|
|
3369
|
+
return eventTimeOffset + thisMessageTime;
|
|
3370
|
+
}
|
|
3371
|
+
|
|
3372
|
+
template <typename EventType>
|
|
3373
|
+
static int64 getEventTime (const EventType& t)
|
|
3374
|
+
{
|
|
3375
|
+
return getEventTime (t.time);
|
|
3376
|
+
}
|
|
3377
|
+
|
|
3378
|
+
void XWindowSystem::handleWindowMessage (LinuxComponentPeer* peer, XEvent& event) const
|
|
3379
|
+
{
|
|
3380
|
+
switch (event.xany.type)
|
|
3381
|
+
{
|
|
3382
|
+
case KeyPressEventType: handleKeyPressEvent (peer, event.xkey); break;
|
|
3383
|
+
case KeyRelease: handleKeyReleaseEvent (peer, event.xkey); break;
|
|
3384
|
+
case ButtonPress: handleButtonPressEvent (peer, event.xbutton); break;
|
|
3385
|
+
case ButtonRelease: handleButtonReleaseEvent (peer, event.xbutton); break;
|
|
3386
|
+
case MotionNotify: handleMotionNotifyEvent (peer, event.xmotion); break;
|
|
3387
|
+
case EnterNotify: handleEnterNotifyEvent (peer, event.xcrossing); break;
|
|
3388
|
+
case LeaveNotify: handleLeaveNotifyEvent (peer, event.xcrossing); break;
|
|
3389
|
+
case FocusIn: handleFocusInEvent (peer); break;
|
|
3390
|
+
case FocusOut: handleFocusOutEvent (peer); break;
|
|
3391
|
+
case Expose: handleExposeEvent (peer, event.xexpose); break;
|
|
3392
|
+
case MappingNotify: handleMappingNotify (event.xmapping); break;
|
|
3393
|
+
case ClientMessage: handleClientMessageEvent (peer, event.xclient, event); break;
|
|
3394
|
+
case SelectionNotify: dragAndDropStateMap[peer].handleDragAndDropSelection (event); break;
|
|
3395
|
+
case ConfigureNotify: handleConfigureNotifyEvent (peer, event.xconfigure); break;
|
|
3396
|
+
case ReparentNotify:
|
|
3397
|
+
case GravityNotify: handleGravityNotify (peer); break;
|
|
3398
|
+
case SelectionClear: dragAndDropStateMap[peer].handleExternalSelectionClear(); break;
|
|
3399
|
+
case SelectionRequest: dragAndDropStateMap[peer].handleExternalSelectionRequest (event); break;
|
|
3400
|
+
case PropertyNotify: propertyNotifyEvent (peer, event.xproperty); break;
|
|
3401
|
+
|
|
3402
|
+
case CirculateNotify:
|
|
3403
|
+
case CreateNotify:
|
|
3404
|
+
case DestroyNotify:
|
|
3405
|
+
case UnmapNotify:
|
|
3406
|
+
break;
|
|
3407
|
+
|
|
3408
|
+
case MapNotify:
|
|
3409
|
+
peer->handleBroughtToFront();
|
|
3410
|
+
break;
|
|
3411
|
+
|
|
3412
|
+
default:
|
|
3413
|
+
#if JUCE_USE_XSHM
|
|
3414
|
+
if (XSHMHelpers::isShmAvailable (display))
|
|
3415
|
+
{
|
|
3416
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3417
|
+
|
|
3418
|
+
if (event.xany.type == shmCompletionEvent)
|
|
3419
|
+
XWindowSystem::getInstance()->removePendingPaintForWindow ((::Window) peer->getNativeHandle());
|
|
3420
|
+
}
|
|
3421
|
+
#endif
|
|
3422
|
+
break;
|
|
3423
|
+
}
|
|
3424
|
+
}
|
|
3425
|
+
|
|
3426
|
+
void XWindowSystem::handleKeyPressEvent (LinuxComponentPeer* peer, XKeyEvent& keyEvent) const
|
|
3427
|
+
{
|
|
3428
|
+
auto oldMods = ModifierKeys::currentModifiers;
|
|
3429
|
+
Keys::refreshStaleModifierKeys();
|
|
3430
|
+
|
|
3431
|
+
char utf8 [64] = { 0 };
|
|
3432
|
+
juce_wchar unicodeChar = 0;
|
|
3433
|
+
int keyCode = 0;
|
|
3434
|
+
bool keyDownChange = false;
|
|
3435
|
+
KeySym sym;
|
|
3436
|
+
|
|
3437
|
+
{
|
|
3438
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3439
|
+
updateKeyStates ((int) keyEvent.keycode, true);
|
|
3440
|
+
|
|
3441
|
+
String oldLocale (::setlocale (LC_ALL, nullptr));
|
|
3442
|
+
::setlocale (LC_ALL, "");
|
|
3443
|
+
X11Symbols::getInstance()->xLookupString (&keyEvent, utf8, sizeof (utf8), &sym, nullptr);
|
|
3444
|
+
|
|
3445
|
+
if (oldLocale.isNotEmpty())
|
|
3446
|
+
::setlocale (LC_ALL, oldLocale.toRawUTF8());
|
|
3447
|
+
|
|
3448
|
+
unicodeChar = *CharPointer_UTF8 (utf8);
|
|
3449
|
+
keyCode = (int) unicodeChar;
|
|
3450
|
+
|
|
3451
|
+
if (keyCode < 0x20)
|
|
3452
|
+
keyCode = (int) X11Symbols::getInstance()->xkbKeycodeToKeysym (display, (::KeyCode) keyEvent.keycode, 0,
|
|
3453
|
+
ModifierKeys::currentModifiers.isShiftDown() ? 1 : 0);
|
|
3454
|
+
|
|
3455
|
+
keyDownChange = (sym != NoSymbol) && ! updateKeyModifiersFromSym (sym, true);
|
|
3456
|
+
}
|
|
3457
|
+
|
|
3458
|
+
bool keyPressed = false;
|
|
3459
|
+
|
|
3460
|
+
if ((sym & 0xff00) == 0xff00 || keyCode == XK_ISO_Left_Tab)
|
|
3461
|
+
{
|
|
3462
|
+
switch (sym) // Translate keypad
|
|
3463
|
+
{
|
|
3464
|
+
case XK_KP_Add: keyCode = XK_plus; break;
|
|
3465
|
+
case XK_KP_Subtract: keyCode = XK_hyphen; break;
|
|
3466
|
+
case XK_KP_Divide: keyCode = XK_slash; break;
|
|
3467
|
+
case XK_KP_Multiply: keyCode = XK_asterisk; break;
|
|
3468
|
+
case XK_KP_Enter: keyCode = XK_Return; break;
|
|
3469
|
+
case XK_KP_Insert: keyCode = XK_Insert; break;
|
|
3470
|
+
case XK_Delete:
|
|
3471
|
+
case XK_KP_Delete: keyCode = XK_Delete; break;
|
|
3472
|
+
case XK_KP_Left: keyCode = XK_Left; break;
|
|
3473
|
+
case XK_KP_Right: keyCode = XK_Right; break;
|
|
3474
|
+
case XK_KP_Up: keyCode = XK_Up; break;
|
|
3475
|
+
case XK_KP_Down: keyCode = XK_Down; break;
|
|
3476
|
+
case XK_KP_Home: keyCode = XK_Home; break;
|
|
3477
|
+
case XK_KP_End: keyCode = XK_End; break;
|
|
3478
|
+
case XK_KP_Page_Down: keyCode = XK_Page_Down; break;
|
|
3479
|
+
case XK_KP_Page_Up: keyCode = XK_Page_Up; break;
|
|
3480
|
+
|
|
3481
|
+
case XK_KP_0: keyCode = XK_0; break;
|
|
3482
|
+
case XK_KP_1: keyCode = XK_1; break;
|
|
3483
|
+
case XK_KP_2: keyCode = XK_2; break;
|
|
3484
|
+
case XK_KP_3: keyCode = XK_3; break;
|
|
3485
|
+
case XK_KP_4: keyCode = XK_4; break;
|
|
3486
|
+
case XK_KP_5: keyCode = XK_5; break;
|
|
3487
|
+
case XK_KP_6: keyCode = XK_6; break;
|
|
3488
|
+
case XK_KP_7: keyCode = XK_7; break;
|
|
3489
|
+
case XK_KP_8: keyCode = XK_8; break;
|
|
3490
|
+
case XK_KP_9: keyCode = XK_9; break;
|
|
3491
|
+
|
|
3492
|
+
default: break;
|
|
3493
|
+
}
|
|
3494
|
+
|
|
3495
|
+
switch (keyCode)
|
|
3496
|
+
{
|
|
3497
|
+
case XK_Left:
|
|
3498
|
+
case XK_Right:
|
|
3499
|
+
case XK_Up:
|
|
3500
|
+
case XK_Down:
|
|
3501
|
+
case XK_Page_Up:
|
|
3502
|
+
case XK_Page_Down:
|
|
3503
|
+
case XK_End:
|
|
3504
|
+
case XK_Home:
|
|
3505
|
+
case XK_Delete:
|
|
3506
|
+
case XK_Insert:
|
|
3507
|
+
keyPressed = true;
|
|
3508
|
+
keyCode = (keyCode & 0xff) | Keys::extendedKeyModifier;
|
|
3509
|
+
break;
|
|
3510
|
+
|
|
3511
|
+
case XK_Tab:
|
|
3512
|
+
case XK_Return:
|
|
3513
|
+
case XK_Escape:
|
|
3514
|
+
case XK_BackSpace:
|
|
3515
|
+
keyPressed = true;
|
|
3516
|
+
keyCode &= 0xff;
|
|
3517
|
+
break;
|
|
3518
|
+
|
|
3519
|
+
case XK_ISO_Left_Tab:
|
|
3520
|
+
keyPressed = true;
|
|
3521
|
+
keyCode = XK_Tab & 0xff;
|
|
3522
|
+
break;
|
|
3523
|
+
|
|
3524
|
+
default:
|
|
3525
|
+
if (sym >= XK_F1 && sym <= XK_F35)
|
|
3526
|
+
{
|
|
3527
|
+
keyPressed = true;
|
|
3528
|
+
keyCode = static_cast<int> ((sym & 0xff) | Keys::extendedKeyModifier);
|
|
3529
|
+
}
|
|
3530
|
+
break;
|
|
3531
|
+
}
|
|
3532
|
+
}
|
|
3533
|
+
|
|
3534
|
+
if (utf8[0] != 0 || ((sym & 0xff00) == 0 && sym >= 8))
|
|
3535
|
+
keyPressed = true;
|
|
3536
|
+
|
|
3537
|
+
if (oldMods != ModifierKeys::currentModifiers)
|
|
3538
|
+
peer->handleModifierKeysChange();
|
|
3539
|
+
|
|
3540
|
+
if (keyDownChange)
|
|
3541
|
+
peer->handleKeyUpOrDown (true);
|
|
3542
|
+
|
|
3543
|
+
if (keyPressed)
|
|
3544
|
+
peer->handleKeyPress (keyCode, unicodeChar);
|
|
3545
|
+
}
|
|
3546
|
+
|
|
3547
|
+
void XWindowSystem::handleKeyReleaseEvent (LinuxComponentPeer* peer, const XKeyEvent& keyEvent) const
|
|
3548
|
+
{
|
|
3549
|
+
auto isKeyReleasePartOfAutoRepeat = [&]() -> bool
|
|
3550
|
+
{
|
|
3551
|
+
if (X11Symbols::getInstance()->xPending (display))
|
|
3552
|
+
{
|
|
3553
|
+
XEvent e;
|
|
3554
|
+
X11Symbols::getInstance()->xPeekEvent (display, &e);
|
|
3555
|
+
|
|
3556
|
+
// Look for a subsequent key-down event with the same timestamp and keycode
|
|
3557
|
+
return e.type == KeyPressEventType
|
|
3558
|
+
&& e.xkey.keycode == keyEvent.keycode
|
|
3559
|
+
&& e.xkey.time == keyEvent.time;
|
|
3560
|
+
}
|
|
3561
|
+
|
|
3562
|
+
return false;
|
|
3563
|
+
}();
|
|
3564
|
+
|
|
3565
|
+
if (! isKeyReleasePartOfAutoRepeat)
|
|
3566
|
+
{
|
|
3567
|
+
updateKeyStates ((int) keyEvent.keycode, false);
|
|
3568
|
+
KeySym sym;
|
|
3569
|
+
|
|
3570
|
+
{
|
|
3571
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3572
|
+
sym = X11Symbols::getInstance()->xkbKeycodeToKeysym (display, (::KeyCode) keyEvent.keycode, 0, 0);
|
|
3573
|
+
}
|
|
3574
|
+
|
|
3575
|
+
auto oldMods = ModifierKeys::currentModifiers;
|
|
3576
|
+
auto keyDownChange = (sym != NoSymbol) && ! updateKeyModifiersFromSym (sym, false);
|
|
3577
|
+
|
|
3578
|
+
if (oldMods != ModifierKeys::currentModifiers)
|
|
3579
|
+
peer->handleModifierKeysChange();
|
|
3580
|
+
|
|
3581
|
+
if (keyDownChange)
|
|
3582
|
+
peer->handleKeyUpOrDown (false);
|
|
3583
|
+
}
|
|
3584
|
+
}
|
|
3585
|
+
|
|
3586
|
+
void XWindowSystem::handleWheelEvent (LinuxComponentPeer* peer, const XButtonPressedEvent& buttonPressEvent, float amount) const
|
|
3587
|
+
{
|
|
3588
|
+
MouseWheelDetails wheel;
|
|
3589
|
+
wheel.deltaX = 0.0f;
|
|
3590
|
+
wheel.deltaY = amount;
|
|
3591
|
+
wheel.isReversed = false;
|
|
3592
|
+
wheel.isSmooth = false;
|
|
3593
|
+
wheel.isInertial = false;
|
|
3594
|
+
|
|
3595
|
+
peer->handleMouseWheel (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (buttonPressEvent, peer->getPlatformScaleFactor()),
|
|
3596
|
+
getEventTime (buttonPressEvent), wheel);
|
|
3597
|
+
}
|
|
3598
|
+
|
|
3599
|
+
void XWindowSystem::handleButtonPressEvent (LinuxComponentPeer* peer, const XButtonPressedEvent& buttonPressEvent, int buttonModifierFlag) const
|
|
3600
|
+
{
|
|
3601
|
+
ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withFlags (buttonModifierFlag);
|
|
3602
|
+
peer->toFront (true);
|
|
3603
|
+
peer->handleMouseEvent (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (buttonPressEvent, peer->getPlatformScaleFactor()),
|
|
3604
|
+
ModifierKeys::currentModifiers, MouseInputSource::defaultPressure,
|
|
3605
|
+
MouseInputSource::defaultOrientation, getEventTime (buttonPressEvent), {});
|
|
3606
|
+
}
|
|
3607
|
+
|
|
3608
|
+
void XWindowSystem::handleButtonPressEvent (LinuxComponentPeer* peer, const XButtonPressedEvent& buttonPressEvent) const
|
|
3609
|
+
{
|
|
3610
|
+
updateKeyModifiers ((int) buttonPressEvent.state);
|
|
3611
|
+
|
|
3612
|
+
auto mapIndex = (uint32) (buttonPressEvent.button - Button1);
|
|
3613
|
+
|
|
3614
|
+
if (mapIndex < (uint32) numElementsInArray (pointerMap))
|
|
3615
|
+
{
|
|
3616
|
+
switch (pointerMap[mapIndex])
|
|
3617
|
+
{
|
|
3618
|
+
case Keys::WheelUp: handleWheelEvent (peer, buttonPressEvent, 50.0f / 256.0f); break;
|
|
3619
|
+
case Keys::WheelDown: handleWheelEvent (peer, buttonPressEvent, -50.0f / 256.0f); break;
|
|
3620
|
+
case Keys::LeftButton: handleButtonPressEvent (peer, buttonPressEvent, ModifierKeys::leftButtonModifier); break;
|
|
3621
|
+
case Keys::RightButton: handleButtonPressEvent (peer, buttonPressEvent, ModifierKeys::rightButtonModifier); break;
|
|
3622
|
+
case Keys::MiddleButton: handleButtonPressEvent (peer, buttonPressEvent, ModifierKeys::middleButtonModifier); break;
|
|
3623
|
+
default: break;
|
|
3624
|
+
}
|
|
3625
|
+
}
|
|
3626
|
+
}
|
|
3627
|
+
|
|
3628
|
+
void XWindowSystem::handleButtonReleaseEvent (LinuxComponentPeer* peer, const XButtonReleasedEvent& buttonRelEvent) const
|
|
3629
|
+
{
|
|
3630
|
+
updateKeyModifiers ((int) buttonRelEvent.state);
|
|
3631
|
+
|
|
3632
|
+
if (peer->getParentWindow() != 0)
|
|
3633
|
+
peer->updateWindowBounds();
|
|
3634
|
+
|
|
3635
|
+
auto mapIndex = (uint32) (buttonRelEvent.button - Button1);
|
|
3636
|
+
|
|
3637
|
+
if (mapIndex < (uint32) numElementsInArray (pointerMap))
|
|
3638
|
+
{
|
|
3639
|
+
switch (pointerMap[mapIndex])
|
|
3640
|
+
{
|
|
3641
|
+
case Keys::LeftButton: ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withoutFlags (ModifierKeys::leftButtonModifier); break;
|
|
3642
|
+
case Keys::RightButton: ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withoutFlags (ModifierKeys::rightButtonModifier); break;
|
|
3643
|
+
case Keys::MiddleButton: ModifierKeys::currentModifiers = ModifierKeys::currentModifiers.withoutFlags (ModifierKeys::middleButtonModifier); break;
|
|
3644
|
+
default: break;
|
|
3645
|
+
}
|
|
3646
|
+
}
|
|
3647
|
+
|
|
3648
|
+
auto& dragState = dragAndDropStateMap[peer];
|
|
3649
|
+
|
|
3650
|
+
if (dragState.isDragging())
|
|
3651
|
+
dragState.handleExternalDragButtonReleaseEvent();
|
|
3652
|
+
|
|
3653
|
+
peer->handleMouseEvent (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (buttonRelEvent, peer->getPlatformScaleFactor()),
|
|
3654
|
+
ModifierKeys::currentModifiers, MouseInputSource::defaultPressure, MouseInputSource::defaultOrientation, getEventTime (buttonRelEvent));
|
|
3655
|
+
}
|
|
3656
|
+
|
|
3657
|
+
void XWindowSystem::handleMotionNotifyEvent (LinuxComponentPeer* peer, const XPointerMovedEvent& movedEvent) const
|
|
3658
|
+
{
|
|
3659
|
+
updateKeyModifiers ((int) movedEvent.state);
|
|
3660
|
+
Keys::refreshStaleMouseKeys();
|
|
3661
|
+
|
|
3662
|
+
auto& dragState = dragAndDropStateMap[peer];
|
|
3663
|
+
|
|
3664
|
+
if (dragState.isDragging())
|
|
3665
|
+
dragState.handleExternalDragMotionNotify();
|
|
3666
|
+
|
|
3667
|
+
peer->handleMouseEvent (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (movedEvent, peer->getPlatformScaleFactor()),
|
|
3668
|
+
ModifierKeys::currentModifiers, MouseInputSource::defaultPressure,
|
|
3669
|
+
MouseInputSource::defaultOrientation, getEventTime (movedEvent));
|
|
3670
|
+
}
|
|
3671
|
+
|
|
3672
|
+
void XWindowSystem::handleEnterNotifyEvent (LinuxComponentPeer* peer, const XEnterWindowEvent& enterEvent) const
|
|
3673
|
+
{
|
|
3674
|
+
if (peer->getParentWindow() != 0)
|
|
3675
|
+
peer->updateWindowBounds();
|
|
3676
|
+
|
|
3677
|
+
if (! ModifierKeys::currentModifiers.isAnyMouseButtonDown())
|
|
3678
|
+
{
|
|
3679
|
+
updateKeyModifiers ((int) enterEvent.state);
|
|
3680
|
+
peer->handleMouseEvent (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (enterEvent, peer->getPlatformScaleFactor()),
|
|
3681
|
+
ModifierKeys::currentModifiers, MouseInputSource::defaultPressure,
|
|
3682
|
+
MouseInputSource::defaultOrientation, getEventTime (enterEvent));
|
|
3683
|
+
}
|
|
3684
|
+
}
|
|
3685
|
+
|
|
3686
|
+
void XWindowSystem::handleLeaveNotifyEvent (LinuxComponentPeer* peer, const XLeaveWindowEvent& leaveEvent) const
|
|
3687
|
+
{
|
|
3688
|
+
// Suppress the normal leave if we've got a pointer grab, or if
|
|
3689
|
+
// it's a bogus one caused by clicking a mouse button when running
|
|
3690
|
+
// in a Window manager
|
|
3691
|
+
if (((! ModifierKeys::currentModifiers.isAnyMouseButtonDown()) && leaveEvent.mode == NotifyNormal)
|
|
3692
|
+
|| leaveEvent.mode == NotifyUngrab)
|
|
3693
|
+
{
|
|
3694
|
+
updateKeyModifiers ((int) leaveEvent.state);
|
|
3695
|
+
peer->handleMouseEvent (MouseInputSource::InputSourceType::mouse, getLogicalMousePos (leaveEvent, peer->getPlatformScaleFactor()),
|
|
3696
|
+
ModifierKeys::currentModifiers, MouseInputSource::defaultPressure,
|
|
3697
|
+
MouseInputSource::defaultOrientation, getEventTime (leaveEvent));
|
|
3698
|
+
}
|
|
3699
|
+
}
|
|
3700
|
+
|
|
3701
|
+
void XWindowSystem::handleFocusInEvent (LinuxComponentPeer* peer) const
|
|
3702
|
+
{
|
|
3703
|
+
peer->isActiveApplication = true;
|
|
3704
|
+
|
|
3705
|
+
if (isFocused ((::Window) peer->getNativeHandle()) && ! peer->focused)
|
|
3706
|
+
{
|
|
3707
|
+
peer->focused = true;
|
|
3708
|
+
peer->handleFocusGain();
|
|
3709
|
+
}
|
|
3710
|
+
}
|
|
3711
|
+
|
|
3712
|
+
void XWindowSystem::handleFocusOutEvent (LinuxComponentPeer* peer) const
|
|
3713
|
+
{
|
|
3714
|
+
if (! isFocused ((::Window) peer->getNativeHandle()) && peer->focused)
|
|
3715
|
+
{
|
|
3716
|
+
peer->focused = false;
|
|
3717
|
+
peer->isActiveApplication = false;
|
|
3718
|
+
|
|
3719
|
+
peer->handleFocusLoss();
|
|
3720
|
+
}
|
|
3721
|
+
}
|
|
3722
|
+
|
|
3723
|
+
void XWindowSystem::handleExposeEvent (LinuxComponentPeer* peer, XExposeEvent& exposeEvent) const
|
|
3724
|
+
{
|
|
3725
|
+
// Batch together all pending expose events
|
|
3726
|
+
XEvent nextEvent;
|
|
3727
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3728
|
+
|
|
3729
|
+
// if we have opengl contexts then just repaint them all
|
|
3730
|
+
// regardless if this is really necessary
|
|
3731
|
+
peer->repaintOpenGLContexts();
|
|
3732
|
+
|
|
3733
|
+
auto windowH = (::Window) peer->getNativeHandle();
|
|
3734
|
+
|
|
3735
|
+
if (exposeEvent.window != windowH)
|
|
3736
|
+
{
|
|
3737
|
+
Window child;
|
|
3738
|
+
X11Symbols::getInstance()->xTranslateCoordinates (display, exposeEvent.window, windowH,
|
|
3739
|
+
exposeEvent.x, exposeEvent.y, &exposeEvent.x, &exposeEvent.y,
|
|
3740
|
+
&child);
|
|
3741
|
+
}
|
|
3742
|
+
|
|
3743
|
+
// exposeEvent is in local window local coordinates so do not convert with
|
|
3744
|
+
// physicalToScaled, but rather use currentScaleFactor
|
|
3745
|
+
auto currentScaleFactor = peer->getPlatformScaleFactor();
|
|
3746
|
+
|
|
3747
|
+
peer->repaint (Rectangle<int> (exposeEvent.x, exposeEvent.y,
|
|
3748
|
+
exposeEvent.width, exposeEvent.height) / currentScaleFactor);
|
|
3749
|
+
|
|
3750
|
+
while (X11Symbols::getInstance()->xEventsQueued (display, QueuedAfterFlush) > 0)
|
|
3751
|
+
{
|
|
3752
|
+
X11Symbols::getInstance()->xPeekEvent (display, &nextEvent);
|
|
3753
|
+
|
|
3754
|
+
if (nextEvent.type != Expose || nextEvent.xany.window != exposeEvent.window)
|
|
3755
|
+
break;
|
|
3756
|
+
|
|
3757
|
+
X11Symbols::getInstance()->xNextEvent (display, &nextEvent);
|
|
3758
|
+
auto& nextExposeEvent = (XExposeEvent&) nextEvent.xexpose;
|
|
3759
|
+
|
|
3760
|
+
peer->repaint (Rectangle<int> (nextExposeEvent.x, nextExposeEvent.y,
|
|
3761
|
+
nextExposeEvent.width, nextExposeEvent.height) / currentScaleFactor);
|
|
3762
|
+
}
|
|
3763
|
+
}
|
|
3764
|
+
|
|
3765
|
+
void XWindowSystem::dismissBlockingModals (LinuxComponentPeer* peer) const
|
|
3766
|
+
{
|
|
3767
|
+
if (peer->getComponent().isCurrentlyBlockedByAnotherModalComponent())
|
|
3768
|
+
if (auto* currentModalComp = Component::getCurrentlyModalComponent())
|
|
3769
|
+
if (auto* otherPeer = currentModalComp->getPeer())
|
|
3770
|
+
if ((otherPeer->getStyleFlags() & ComponentPeer::windowIsTemporary) != 0)
|
|
3771
|
+
currentModalComp->inputAttemptWhenModal();
|
|
3772
|
+
}
|
|
3773
|
+
|
|
3774
|
+
void XWindowSystem::handleConfigureNotifyEvent (LinuxComponentPeer* peer, XConfigureEvent& confEvent) const
|
|
3775
|
+
{
|
|
3776
|
+
peer->updateWindowBounds();
|
|
3777
|
+
peer->updateBorderSize();
|
|
3778
|
+
peer->handleMovedOrResized();
|
|
3779
|
+
|
|
3780
|
+
// if the native title bar is dragged, need to tell any active menus, etc.
|
|
3781
|
+
if ((peer->getStyleFlags() & ComponentPeer::windowHasTitleBar) != 0)
|
|
3782
|
+
dismissBlockingModals (peer);
|
|
3783
|
+
|
|
3784
|
+
auto windowH = (::Window) peer->getNativeHandle();
|
|
3785
|
+
|
|
3786
|
+
if (confEvent.window == windowH && confEvent.above != 0 && isFrontWindow (windowH))
|
|
3787
|
+
peer->handleBroughtToFront();
|
|
3788
|
+
}
|
|
3789
|
+
|
|
3790
|
+
void XWindowSystem::handleGravityNotify (LinuxComponentPeer* peer) const
|
|
3791
|
+
{
|
|
3792
|
+
peer->updateWindowBounds();
|
|
3793
|
+
peer->updateBorderSize();
|
|
3794
|
+
peer->handleMovedOrResized();
|
|
3795
|
+
}
|
|
3796
|
+
|
|
3797
|
+
bool XWindowSystem::isIconic (Window w) const
|
|
3798
|
+
{
|
|
3799
|
+
jassert (w != 0);
|
|
3800
|
+
|
|
3801
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3802
|
+
XWindowSystemUtilities::GetXProperty prop (display, w, atoms.state, 0, 64, false, atoms.state);
|
|
3803
|
+
|
|
3804
|
+
if (prop.success && prop.actualType == atoms.state
|
|
3805
|
+
&& prop.actualFormat == 32 && prop.numItems > 0)
|
|
3806
|
+
{
|
|
3807
|
+
unsigned long state;
|
|
3808
|
+
memcpy (&state, prop.data, sizeof (unsigned long));
|
|
3809
|
+
|
|
3810
|
+
return state == IconicState;
|
|
3811
|
+
}
|
|
3812
|
+
|
|
3813
|
+
return false;
|
|
3814
|
+
}
|
|
3815
|
+
|
|
3816
|
+
bool XWindowSystem::isHidden (Window w) const
|
|
3817
|
+
{
|
|
3818
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3819
|
+
XWindowSystemUtilities::GetXProperty prop (display, w, atoms.windowState, 0, 128, false, XA_ATOM);
|
|
3820
|
+
|
|
3821
|
+
if (! (prop.success && prop.actualFormat == 32 && prop.actualType == XA_ATOM))
|
|
3822
|
+
return false;
|
|
3823
|
+
|
|
3824
|
+
const auto* data = unalignedPointerCast<const long*> (prop.data);
|
|
3825
|
+
const auto end = data + prop.numItems;
|
|
3826
|
+
|
|
3827
|
+
return std::find (data, end, atoms.windowStateHidden) != end;
|
|
3828
|
+
}
|
|
3829
|
+
|
|
3830
|
+
void XWindowSystem::propertyNotifyEvent (LinuxComponentPeer* peer, const XPropertyEvent& event) const
|
|
3831
|
+
{
|
|
3832
|
+
if ((event.atom == atoms.state && isIconic (event.window))
|
|
3833
|
+
|| (event.atom == atoms.windowState && isHidden (event.window)))
|
|
3834
|
+
{
|
|
3835
|
+
dismissBlockingModals (peer);
|
|
3836
|
+
}
|
|
3837
|
+
|
|
3838
|
+
if (event.atom == XWindowSystemUtilities::Atoms::getIfExists (display, "_NET_FRAME_EXTENTS"))
|
|
3839
|
+
peer->updateBorderSize();
|
|
3840
|
+
}
|
|
3841
|
+
|
|
3842
|
+
void XWindowSystem::handleMappingNotify (XMappingEvent& mappingEvent) const
|
|
3843
|
+
{
|
|
3844
|
+
if (mappingEvent.request != MappingPointer)
|
|
3845
|
+
{
|
|
3846
|
+
// Deal with modifier/keyboard mapping
|
|
3847
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3848
|
+
X11Symbols::getInstance()->xRefreshKeyboardMapping (&mappingEvent);
|
|
3849
|
+
updateModifierMappings();
|
|
3850
|
+
}
|
|
3851
|
+
}
|
|
3852
|
+
|
|
3853
|
+
void XWindowSystem::handleClientMessageEvent (LinuxComponentPeer* peer, XClientMessageEvent& clientMsg, XEvent& event) const
|
|
3854
|
+
{
|
|
3855
|
+
if (clientMsg.message_type == atoms.protocols && clientMsg.format == 32)
|
|
3856
|
+
{
|
|
3857
|
+
auto atom = (Atom) clientMsg.data.l[0];
|
|
3858
|
+
|
|
3859
|
+
if (atom == atoms.protocolList [XWindowSystemUtilities::Atoms::PING])
|
|
3860
|
+
{
|
|
3861
|
+
auto root = X11Symbols::getInstance()->xRootWindow (display, X11Symbols::getInstance()->xDefaultScreen (display));
|
|
3862
|
+
|
|
3863
|
+
clientMsg.window = root;
|
|
3864
|
+
|
|
3865
|
+
X11Symbols::getInstance()->xSendEvent (display, root, False, NoEventMask, &event);
|
|
3866
|
+
X11Symbols::getInstance()->xFlush (display);
|
|
3867
|
+
}
|
|
3868
|
+
else if (atom == atoms.protocolList [XWindowSystemUtilities::Atoms::TAKE_FOCUS])
|
|
3869
|
+
{
|
|
3870
|
+
if ((peer->getStyleFlags() & ComponentPeer::windowIgnoresKeyPresses) == 0)
|
|
3871
|
+
{
|
|
3872
|
+
XWindowAttributes atts;
|
|
3873
|
+
|
|
3874
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
3875
|
+
if (clientMsg.window != 0
|
|
3876
|
+
&& X11Symbols::getInstance()->xGetWindowAttributes (display, clientMsg.window, &atts))
|
|
3877
|
+
{
|
|
3878
|
+
if (atts.map_state == IsViewable)
|
|
3879
|
+
{
|
|
3880
|
+
auto windowH = (::Window) peer->getNativeHandle();
|
|
3881
|
+
|
|
3882
|
+
X11Symbols::getInstance()->xSetInputFocus (display, (clientMsg.window == windowH ? getFocusWindow (windowH)
|
|
3883
|
+
: clientMsg.window),
|
|
3884
|
+
RevertToParent, (::Time) clientMsg.data.l[1]);
|
|
3885
|
+
}
|
|
3886
|
+
}
|
|
3887
|
+
}
|
|
3888
|
+
}
|
|
3889
|
+
else if (atom == atoms.protocolList [XWindowSystemUtilities::Atoms::DELETE_WINDOW])
|
|
3890
|
+
{
|
|
3891
|
+
peer->handleUserClosingWindow();
|
|
3892
|
+
}
|
|
3893
|
+
}
|
|
3894
|
+
else if (clientMsg.message_type == atoms.XdndEnter)
|
|
3895
|
+
{
|
|
3896
|
+
dragAndDropStateMap[peer].handleDragAndDropEnter (clientMsg, peer);
|
|
3897
|
+
}
|
|
3898
|
+
else if (clientMsg.message_type == atoms.XdndLeave)
|
|
3899
|
+
{
|
|
3900
|
+
dragAndDropStateMap[peer].handleDragAndDropExit();
|
|
3901
|
+
}
|
|
3902
|
+
else if (clientMsg.message_type == atoms.XdndPosition)
|
|
3903
|
+
{
|
|
3904
|
+
dragAndDropStateMap[peer].handleDragAndDropPosition (clientMsg, peer);
|
|
3905
|
+
}
|
|
3906
|
+
else if (clientMsg.message_type == atoms.XdndDrop)
|
|
3907
|
+
{
|
|
3908
|
+
dragAndDropStateMap[peer].handleDragAndDropDrop (clientMsg, peer);
|
|
3909
|
+
}
|
|
3910
|
+
else if (clientMsg.message_type == atoms.XdndStatus)
|
|
3911
|
+
{
|
|
3912
|
+
dragAndDropStateMap[peer].handleExternalDragAndDropStatus (clientMsg);
|
|
3913
|
+
}
|
|
3914
|
+
else if (clientMsg.message_type == atoms.XdndFinished)
|
|
3915
|
+
{
|
|
3916
|
+
dragAndDropStateMap[peer].externalResetDragAndDrop();
|
|
3917
|
+
}
|
|
3918
|
+
else if (clientMsg.message_type == atoms.XembedMsgType && clientMsg.format == 32)
|
|
3919
|
+
{
|
|
3920
|
+
handleXEmbedMessage (peer, clientMsg);
|
|
3921
|
+
}
|
|
3922
|
+
}
|
|
3923
|
+
|
|
3924
|
+
void XWindowSystem::handleXEmbedMessage (LinuxComponentPeer* peer, XClientMessageEvent& clientMsg) const
|
|
3925
|
+
{
|
|
3926
|
+
switch (clientMsg.data.l[1])
|
|
3927
|
+
{
|
|
3928
|
+
case 0: // XEMBED_EMBEDDED_NOTIFY
|
|
3929
|
+
peer->setParentWindow ((::Window) clientMsg.data.l[3]);
|
|
3930
|
+
peer->updateWindowBounds();
|
|
3931
|
+
peer->getComponent().setBounds (peer->getBounds());
|
|
3932
|
+
break;
|
|
3933
|
+
case 4: // XEMBED_FOCUS_IN
|
|
3934
|
+
handleFocusInEvent (peer);
|
|
3935
|
+
break;
|
|
3936
|
+
case 5: // XEMBED_FOCUS_OUT
|
|
3937
|
+
handleFocusOutEvent (peer);
|
|
3938
|
+
break;
|
|
3939
|
+
|
|
3940
|
+
default:
|
|
3941
|
+
break;
|
|
3942
|
+
}
|
|
3943
|
+
}
|
|
3944
|
+
|
|
3945
|
+
//==============================================================================
|
|
3946
|
+
void XWindowSystem::dismissBlockingModals (LinuxComponentPeer* peer, const XConfigureEvent& configure) const
|
|
3947
|
+
{
|
|
3948
|
+
if (peer == nullptr)
|
|
3949
|
+
return;
|
|
3950
|
+
|
|
3951
|
+
const auto peerHandle = peer->getWindowHandle();
|
|
3952
|
+
|
|
3953
|
+
if (configure.window != peerHandle && isParentWindowOf (configure.window, peerHandle))
|
|
3954
|
+
dismissBlockingModals (peer);
|
|
3955
|
+
}
|
|
3956
|
+
|
|
3957
|
+
void XWindowSystem::windowMessageReceive (XEvent& event)
|
|
3958
|
+
{
|
|
3959
|
+
if (event.xany.window != None)
|
|
3960
|
+
{
|
|
3961
|
+
#if JUCE_X11_SUPPORTS_XEMBED
|
|
3962
|
+
if (! juce_handleXEmbedEvent (nullptr, &event))
|
|
3963
|
+
#endif
|
|
3964
|
+
{
|
|
3965
|
+
auto* instance = XWindowSystem::getInstance();
|
|
3966
|
+
|
|
3967
|
+
if (auto* xSettings = instance->getXSettings())
|
|
3968
|
+
{
|
|
3969
|
+
if (event.xany.window == xSettings->getSettingsWindow())
|
|
3970
|
+
{
|
|
3971
|
+
if (event.xany.type == PropertyNotify)
|
|
3972
|
+
xSettings->update();
|
|
3973
|
+
else if (event.xany.type == DestroyNotify)
|
|
3974
|
+
instance->initialiseXSettings();
|
|
3975
|
+
|
|
3976
|
+
return;
|
|
3977
|
+
}
|
|
3978
|
+
}
|
|
3979
|
+
|
|
3980
|
+
if (auto* peer = dynamic_cast<LinuxComponentPeer*> (getPeerFor (event.xany.window)))
|
|
3981
|
+
{
|
|
3982
|
+
XWindowSystem::getInstance()->handleWindowMessage (peer, event);
|
|
3983
|
+
return;
|
|
3984
|
+
}
|
|
3985
|
+
|
|
3986
|
+
if (event.type != ConfigureNotify)
|
|
3987
|
+
return;
|
|
3988
|
+
|
|
3989
|
+
for (auto i = ComponentPeer::getNumPeers(); --i >= 0;)
|
|
3990
|
+
instance->dismissBlockingModals (dynamic_cast<LinuxComponentPeer*> (ComponentPeer::getPeer (i)),
|
|
3991
|
+
event.xconfigure);
|
|
3992
|
+
}
|
|
3993
|
+
}
|
|
3994
|
+
else if (event.xany.type == KeymapNotify)
|
|
3995
|
+
{
|
|
3996
|
+
auto& keymapEvent = (const XKeymapEvent&) event.xkeymap;
|
|
3997
|
+
memcpy (Keys::keyStates, keymapEvent.key_vector, 32);
|
|
3998
|
+
}
|
|
3999
|
+
}
|
|
4000
|
+
|
|
4001
|
+
//==============================================================================
|
|
4002
|
+
JUCE_IMPLEMENT_SINGLETON (XWindowSystem)
|
|
4003
|
+
|
|
4004
|
+
Image createSnapshotOfNativeWindow (void* window)
|
|
4005
|
+
{
|
|
4006
|
+
::Window root;
|
|
4007
|
+
int wx, wy;
|
|
4008
|
+
unsigned int ww, wh, bw, bitDepth;
|
|
4009
|
+
|
|
4010
|
+
XWindowSystemUtilities::ScopedXLock xLock;
|
|
4011
|
+
|
|
4012
|
+
const auto display = XWindowSystem::getInstance()->getDisplay();
|
|
4013
|
+
|
|
4014
|
+
if (! X11Symbols::getInstance()->xGetGeometry (display, (::Drawable) window, &root, &wx, &wy, &ww, &wh, &bw, &bitDepth))
|
|
4015
|
+
return {};
|
|
4016
|
+
|
|
4017
|
+
const auto scale = []
|
|
4018
|
+
{
|
|
4019
|
+
if (auto* d = Desktop::getInstance().getDisplays().getPrimaryDisplay())
|
|
4020
|
+
return d->scale;
|
|
4021
|
+
|
|
4022
|
+
return 1.0;
|
|
4023
|
+
}();
|
|
4024
|
+
|
|
4025
|
+
auto image = Image { new XBitmapImage { X11Symbols::getInstance()->xGetImage (display,
|
|
4026
|
+
(::Drawable) window,
|
|
4027
|
+
0,
|
|
4028
|
+
0,
|
|
4029
|
+
ww,
|
|
4030
|
+
wh,
|
|
4031
|
+
AllPlanes,
|
|
4032
|
+
ZPixmap) } };
|
|
4033
|
+
return image.rescaled ((int) ((double) ww / scale), (int) ((double) wh / scale));
|
|
4034
|
+
}
|
|
4035
|
+
|
|
4036
|
+
} // namespace juce
|