1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-13 00:04:19 +00:00
Commit graph

300 commits

Author SHA1 Message Date
reuk
1c1cbdf18d
ComponentBoundsConstrainer: Add new decorator constrainer 2023-05-31 15:15:25 +01:00
attila
909f6c43d2 Grid: Fix incorrect computation
One issue affected the situation where the provided bounds wouldn't
start at (0, 0). Such bounds are regularly acquired by calling
Rectangle::reduced().

The other issue affected the width calculation of fractional items.
The error wasn't correctly integrated during the computation, and as a
consequence the last fractional element would exhibit all the
accumulated error.
2023-05-04 17:01:02 +02:00
attila
a6761f9eb8 Grid: Ensure that items with absolute sizes will maintain correctly rounded dimensions
Prior to this commit all Grid calculations were carried out using
floating point numbers. The dimensions of all items would then be
rounded with the same function to calculate the integer dimensions used
for Component layout. This resulted in layout solutions where the width
or height of items with dimensions specified using the absolute Px
quantity could differ from the correctly rounded value of these values.

This commit ensures that the width and height of these items are always
correct and their cumulative error in size is distributed among items
with fractional dimensions.
2023-04-26 11:05:53 +02:00
reuk
28414a6af8
Global: Avoid floating-point equality checks where possible 2023-04-04 19:55:11 +01:00
Oli
d264d95595 StretchableLayoutManager: Prevent zero size layouts 2023-04-04 10:06:40 +01:00
Anthony Nicholls
cff722a4af GUI Basics: Refactor juce_gui_basics file structure
- Created a new detail namespace
- Moved shared module implementation details into the detail namespace
- Split dependencies so source files only rely on details in the detail namespace
- Removed all code from the juce_gui_basics.cpp file
2023-03-16 08:53:12 +00:00
reuk
9cfbccca8e
Accessibility: Make createAccessibilityHandler public to allow calls from derived classes 2023-02-09 17:54:18 +00:00
reuk
eee7200629 SidePanel: Fix shadow drawing artefact on hi-res screens 2022-12-14 18:59:44 +00:00
reuk
28f2157912
Convert ignoreUnused to [[maybe_unused]] 2022-12-01 11:41:50 +00:00
attila
44dd0649fd Grid: Fix layout for very small items
Until this commit Items with a size of 1 could be rounded to
bounds with a size of 0 or 2 due to floating point errors, leading
to slightly too large or disappearing items. The new approach
preserves the size of items.
2022-09-22 18:18:59 +02:00
attila
3acc71f7df MultiDocumentPanel: Fix reporting wrong active document, avoid reordering 2022-07-11 15:13:08 +02:00
attila
27924e4996 Viewport: Stop ongoing physical drag upon user interaction
An animated drag operation will now stop if the user interacts with
the content area again before the animation is finished. It is also
stopped if the user interacts with the scrollbars.
2022-06-30 15:10:15 +00:00
reuk
7eb99ed8ec
Grid: Avoid hangs when positioning auto-placement items that are too large for the explicit grid
Previously, positioning such an item would hang while trying to find an
appropriate position for the item, because no position in the grid was
suitable, and implicit cells in the layout direction would be added
until a viable position was found.

We now ensure that there are enough cells in the cross direction to hold
each of the auto-placement items before trying to position those items.
2022-06-24 18:53:59 +01:00
reuk
53484db875
Accessibility: Avoid allowing TextEditor and Viewport internal components to be accessibility-focused
The TextHolderComponent and Viewport::componentHolder don't have any
accessible semantics, so they shouldn't be included in the accessible
component hierarchy.
2022-06-13 15:29:57 +01:00
Tom Poole
2ec861d99e Update licensing banners to JUCE 7 2022-05-16 17:55:48 +01:00
Tom Poole
669782cdf4 Viewport: Fix a scrolling bug when internal components have a transform applied 2022-04-27 12:02:10 +01:00
reuk
858aab823a
ComponentBoundsConstrainer: Properly constrain secondary windows in plugins 2022-04-22 14:18:50 +01:00
Tom Poole
dea3fe60e4 Update copyright banners 2022-04-04 12:36:32 +01:00
reuk
1d1d743b9f
Build: Add -Wdeprecated to recommended flags and fix new warnings 2022-02-23 10:56:10 +00:00
reuk
84db4b186f
ComponentBoundsConstrainer: Refactor 2022-02-18 16:43:25 +00:00
reuk
4cf74dfff6 Viewport: Improve drag-to-scroll on devices that can accept simultaneous mouse and touch input
Some Windows 11 devices have both touch screens and mouse inputs, and
these can be used simultaneously.

The Viewport (and ListBox) now check the input source of each mouse
down. If the source is not a mouse, the viewport will always enter
drag-to-scroll mode, regardless of the result of isScrollOnDragEnabled.
2022-02-07 14:24:11 +00:00
attila
6575d24a81 ComponentPeer: Deprecate getFrameSize() 2022-02-03 21:46:36 +01:00
Tom Poole
c072b1bc8e Fix some typos 2022-01-25 11:48:46 +00:00
reuk
e247e06fb7
FlexBox: Refactor and tidy implementation 2021-11-19 16:35:21 +00:00
reuk
0dad809264
FlexBox: Add tests, and fix layout bugs 2021-11-19 16:35:20 +00:00
reuk
4d572411e0
FlexBox: Update the default value of FlexItem::alignSelf to match CSS implementations 2021-10-26 16:52:16 +01:00
reuk
6bc51f97e4
Grid: Avoid crashing in performLayout when the grid contains no items 2021-10-14 12:40:25 +01:00
ed
051e0ed6d6 Fix leak on MultiDocumentPanel destruction 2021-10-07 14:30:32 +01:00
reuk
c3c171acaf
Grid: Fix behaviour with negative row/column indices
Negative indices should count backwards from the last explicit
row/column number. If the resulting line number would appear before
the first explicit row/column, implicit grid lines should be added
before the first explicit row/column.
2021-09-28 11:31:49 +01:00
reuk
c802319241
Viewport: Stop touches on other components from interrupting scrolling
Previously, a touch on a component outside the Viewport would interrupt
and cancel a scroll gesture inside the Viewport.

Now, the Viewport will respond to all drag events from the input source
that started the drag, allowing the Viewport to be scrolled with one
input source while adjusting other controls with another input source.

The FontsDemo is useful for testing this behaviour, as it has two
Viewports on a single screen, along with some other controls.
2021-09-27 15:46:28 +01:00
ed
90eb878d16 Accessibility: Make createAccessibilityHandler() private in Component subclasses 2021-09-07 11:23:17 +01:00
ed
8d6ba3b54e Accessibility: Use AccessibilityRole::ignored for UI elements that should not be accessible to screen readers but have accessible children 2021-09-07 11:23:17 +01:00
ed
a5c3b81f82 Use C++14 lambda capture initialisers for initialising deletion checkers 2021-07-12 11:58:29 +01:00
Tom Poole
fe4ba9071b Set the default value of JUCE_MODAL_LOOPS_PERMITTED to 0
See BREAKING-CHANGES.txt for more details.
2021-06-30 13:01:14 +01:00
ed
bbc05adb17 Docs: Updated Viewport scrollbar docs 2021-06-07 19:38:29 +01:00
reuk
31a7c62baf
Windows: Fix and suppress some analysis warnings
This fixes warnings that are emitted when building with the `-analyze`
flag enabled.
2021-05-26 15:34:26 +01:00
ed
9147a5e535 Accessibility: Ignore Viewport content holder 2021-05-20 18:24:58 +01:00
ed
333983947e Accessibility: Removed widget_handlers 2021-05-20 18:24:56 +01:00
ed
ec990202b1 Accessibility: Added VoiceOver (macOS) and Narrator (Windows) accessibility screen reader support to juce_gui_basics 2021-05-10 10:53:14 +01:00
ed
bd17993caa SidePanel: Call onPanelShowHide when animation has completed 2021-04-27 15:56:01 +01:00
ed
d7358d0ef1 Update SidePanel visibility when shown/hidden and set always on top 2021-01-29 15:40:12 +00:00
reuk
586ab8927d Fix warnings when building in C++20 mode 2021-01-15 13:33:40 +00:00
ed
b7e28541ca Replaced deprecated Displays methods 2020-10-27 12:38:59 +00:00
reuk
394c4fd475 Clang: Fix warnings when building with clang 10 2020-07-01 10:00:43 +01:00
ed
009d685179 Updated all license headers 2020-06-29 08:30:22 +01:00
ed
b5214a341e Normalised lambda whitespace 2020-06-05 09:37:56 +01:00
ed
d510b73cdf Normalised all whitespace before args in std::function 2020-06-05 09:37:49 +01:00
ed
685dc4fd78 Fixed a typo 2020-05-20 18:38:39 +01:00
Tom Poole
894e7d2bd2 Updated all license headers 2020-04-23 17:30:39 +01:00
reuk
327f817b9b Copyrights: Update commercial/gpl headers to be gpl-only 2020-04-09 15:22:56 +01:00