Commit Graph

170 Commits

Author SHA1 Message Date
Hans Goudey 91e54fdd83 Cleanup: Move BLO_readfile.h to C++
I added a new BLO_userdef_default.h header to contain declarations of
two global variables that are still defined in C files. Use of designated
initializers for large structs make those files harder to change.
Arguably this is a better header for them anyway.

Pull Request: https://projects.blender.org/blender/blender/pulls/118015
2024-02-09 13:41:30 +01:00
Gilberto Rodrigues dfd1b63cc7 UI: improve mesh edge highlighting
Changes to edit mode mesh overlays, use hue shift instead of color
fading/darkening for selection mode visual differentiation, and some
theme changes to improve the display of mesh edges and faces with good
selection visibility.

- Removed "edge" toggle from edit mode overlays panel.
- No longer halves the edge and face alpha depending on selection mode.
  Half the face alpha in wire-frame mode. For better visibility on most
  themes.

Ref !111431
2023-11-02 22:09:17 +11:00
Pablo Vazquez fd1a5b52c1 Theme: do not mark pulldown menus as active on hover
Match the color of regular menu items on hover.

Do versioning comes right after since it's needed for another bug.
2023-10-31 13:04:59 +01:00
Richard Antalik 86a0d0015a VSE: Improve retiming UI
Currently retiming is quite awkward, when you need to retime multiple
strips strips in sync. It is possible to use meta strips, but this is
still not great. This is resolved by implementing selection.

General changes:
Gizmos are removed, since they are designed to operate only on active
strip and don't support selection.
Transform operator code is implemented for retiming data, which allows
more sophisticated manipulation.
Instead of drawing marker-like symbols, keyframes are drawn to
represent retiming data. Retiming handles are now called keys. To have
consistent names, DNA structures have been renamed.
Retiming data is drawn on strip as overlay.

UI changes:
Retiming tool is removed. To edit retiming data, press Ctrl + R, select
a key and move it. When retiming is edited, retiming menu and
context menu shows more relevant features, like making transitions.
Strip and retiming key selection can not be combined. It is possible to
use box select operator to select keys, if any key is selected.
Otherwise strips are selected.
Adding retiming keys is possible with I shortcut or from menu.
Retiming keys are always drawn at strip left and right boundary. These
keys do not really exist until they are selected. This is to simplify
retiming of strips that are resized. These keys are called "fake keys"
in code.

API changes:
Functions, properties and types related to retiming handles are renamed
to retiming keys:
retiming_handle_add() -> retiming_key_add()
retiming_handle_move() -> retiming_key_move()
retiming_handle_remove() -> retiming_key_remove()
retiming_handles -> retiming_keys
RetimingHandle -> RetimingKey

Retiming editing "mode" is activated by setting `Sequence.show_retiming_keys`.

Pull Request: https://projects.blender.org/blender/blender/pulls/109044
2023-09-27 01:45:59 +02:00
Pablo Vazquez 2f31077463 Fix #112032: Theme: Wrong colors editing list items
Fixed by using a slightly transparent white color that blends
correctly with the background of text inputs and list items.

Also use the same colors in the Text Editor for consistency in both
Dark and Light themes.
2023-09-15 13:00:05 +02:00
Rawalanche 0e090369d6 Fix #109439: Use List Item widget colors for View Item widgets
As concluded in discussion under #109439, the View Item widgets are
supposed to use List Item widget theme colors. This patch does that.

Co-authored-by: Harley Acheson <harley.acheson@gmail.com>
Pull Request: https://projects.blender.org/blender/blender/pulls/111584
2023-09-01 20:02:20 +02:00
Pablo Vazquez eef2b61e91 Theme: Set 3D Viewport background to single color
The default vignette effect introduces issues reported several times
on various hardware configurations.

It would still be nice to figure out the issue and fix it in the
vignette effect code. For now, simply use single-color in the
default theme.

As agreed during the 2023-08-15 User Interface Module meeting.

Fixes #93627
Closes #106699
2023-08-16 18:45:21 +02:00
Campbell Barton e955c94ed3 License Headers: Set copyright to "Blender Authors", add AUTHORS
Listing the "Blender Foundation" as copyright holder implied the Blender
Foundation holds copyright to files which may include work from many
developers.

While keeping copyright on headers makes sense for isolated libraries,
Blender's own code may be refactored or moved between files in a way
that makes the per file copyright holders less meaningful.

Copyright references to the "Blender Foundation" have been replaced with
"Blender Authors", with the exception of `./extern/` since these this
contains libraries which are more isolated, any changed to license
headers there can be handled on a case-by-case basis.

Some directories in `./intern/` have also been excluded:

- `./intern/cycles/` it's own `AUTHORS` file is planned.
- `./intern/opensubdiv/`.

An "AUTHORS" file has been added, using the chromium projects authors
file as a template.

Design task: #110784

Ref !110783.
2023-08-16 00:20:26 +10:00
ok_what 5f0a8759b0 VSE: Improve drawing of strip title and preview
This patch includes set of smaller changes to address visual
inconsistencies and bugs:

- Strip previews are drawn under title bar
- All strip previews now disappear when there isn't enough space for
  drawing
- Like the sound strip, the color strip expands to fill the whole strip
  when there is little vertical space, "taking over" the strip title
  Color is more important visual indicator than the name of the strip
- Disabling strip title no longer disables strip handle frame previews
- All strip previews are now be affected by the "Show overlays" toggle
- Turning off strip text overlay no longer makes the color strip
  preview disappear
2023-08-07 21:35:45 +02:00
Julian Eisel 8b19477e9c UI: Support asset shelves in 3D Views
The previous commit introduced all the basic bits and pieces necessary
to support asset shelves as experimental feature, but didn't actually
add support for any specific editor. With this commit asset shelves can
be registered in 3D Views, which should soon be used by the Pose Library
add-on to replace its previous UI in the sidebar (see
blender/blender-addons#104546). Note that until then, there will still be no
actual asset shelf to display.

Also adds:
- Toggle to hide/unhide the asset shelf under "View" -> "Asset Shelf"
- 3D View theme settings for the asset shelf regions.

None of the changes are visible if the experimental option for the asset
shelf is not enabled.

Approved as part of #104831, then split off as separate commit.

Pull Request: #110767
2023-08-03 16:59:50 +02:00
Jacques Lucke 3d73b71a97 Geometry Nodes: new Repeat Zone
This adds support for running a set of nodes repeatedly. The number
of iterations can be controlled dynamically as an input of the repeat
zone. The repeat zone can be added in via the search or from the
Add > Utilities menu.

The main use case is to replace long repetitive node chains with a more
flexible alternative. Technically, repeat zones can also be used for
many other use cases. However, due to their serial nature, performance
is very  sub-optimal when they are used to solve problems that could
be processed in parallel. Better solutions for such use cases will
be worked on separately.

Repeat zones are similar to simulation zones. The major difference is
that they have no concept of time and are always evaluated entirely in
the current frame, while in simulations only a single iteration is
evaluated per frame.

Stopping the repetition early using a dynamic condition is not yet
supported. "Break" functionality can be implemented manually using
Switch nodes in the  loop for now. It's likely that this functionality
will be built into the repeat zone in the future.
For now, things are kept more simple.

Remaining Todos after this first version:
* Improve socket inspection and viewer node support. Currently, only
  the first iteration is taken into account for socket inspection
  and the viewer.
* Make loop evaluation more lazy. Currently, the evaluation is eager,
  meaning that it evaluates some nodes even though their output may not
  be required.

Pull Request: https://projects.blender.org/blender/blender/pulls/109164
2023-07-11 22:36:10 +02:00
Campbell Barton 65f99397ec License headers: use SPDX-FileCopyrightText in all sources 2023-06-15 13:35:34 +10:00
Jacques Lucke 493c4dd65b Geometry Nodes: add theme option for simulated frames in timeline
The new theme setting for the dope sheet (timeline) allows changing the
color of the bar that shows which frames are cached/baked. The
invalid/cached/baked status is differentiated by hardcoded transparency
values. In theory, those could be separate theme settings though.

Pull Request: https://projects.blender.org/blender/blender/pulls/107738
2023-05-10 14:19:27 +02:00
Jacques Lucke 0de54b84c6 Geometry Nodes: add simulation support
This adds support for building simulations with geometry nodes. A new
`Simulation Input` and `Simulation Output` node allow maintaining a
simulation state across multiple frames. Together these two nodes form
a `simulation zone` which contains all the nodes that update the simulation
state from one frame to the next.

A new simulation zone can be added via the menu
(`Simulation > Simulation Zone`) or with the node add search.

The simulation state contains a geometry by default. However, it is possible
to add multiple geometry sockets as well as other socket types. Currently,
field inputs are evaluated and stored for the preceding geometry socket in
the order that the sockets are shown. Simulation state items can be added
by linking one of the empty sockets to something else. In the sidebar, there
is a new panel that allows adding, removing and reordering these sockets.

The simulation nodes behave as follows:
* On the first frame, the inputs of the `Simulation Input` node are evaluated
  to initialize the simulation state. In later frames these sockets are not
  evaluated anymore. The `Delta Time` at the first frame is zero, but the
  simulation zone is still evaluated.
* On every next frame, the `Simulation Input` node outputs the simulation
  state of the previous frame. Nodes in the simulation zone can edit that
  data in arbitrary ways, also taking into account the `Delta Time`. The new
  simulation state has to be passed to the `Simulation Output` node where it
  is cached and forwarded.
* On a frame that is already cached or baked, the nodes in the simulation
  zone are not evaluated, because the `Simulation Output` node can return
  the previously cached data directly.

It is not allowed to connect sockets from inside the simulation zone to the
outside without going through the `Simulation Output` node. This is a necessary
restriction to make caching and sub-frame interpolation work. Links can go into
the simulation zone without problems though.

Anonymous attributes are not propagated by the simulation nodes unless they
are explicitly stored in the simulation state. This is unfortunate, but
currently there is no practical and reliable alternative. The core problem
is detecting which anonymous attributes will be required for the simulation
and afterwards. While we can detect this for the current evaluation, we can't
look into the future in time to see what data will be necessary. We intend to
make it easier to explicitly pass data through a simulation in the future,
even if the simulation is in a nested node group.

There is a new `Simulation Nodes` panel in the physics tab in the properties
editor. It allows baking all simulation zones on the selected objects. The
baking options are intentially kept at a minimum for this MVP. More features
for simulation baking as well as baking in general can be expected to be added
separately.

All baked data is stored on disk in a folder next to the .blend file. #106937
describes how baking is implemented in more detail. Volumes can not be baked
yet and materials are lost during baking for now. Packing the baked data into
the .blend file is not yet supported.

The timeline indicates which frames are currently cached, baked or cached but
invalidated by user-changes.

Simulation input and output nodes are internally linked together by their
`bNode.identifier` which stays the same even if the node name changes. They
are generally added and removed together. However, there are still cases where
"dangling" simulation nodes can be created currently. Those generally don't
cause harm, but would be nice to avoid this in more cases in the future.

Co-authored-by: Hans Goudey <h.goudey@me.com>
Co-authored-by: Lukas Tönne <lukas@blender.org>

Pull Request: https://projects.blender.org/blender/blender/pulls/104924
2023-05-03 13:18:59 +02:00
Campbell Barton aa82afaaf7 Cleanup: regenerate the default theme file
Re-run ./tools/utils/blender_theme_as_c.py
2023-03-03 16:32:38 +11:00
bonj dcad51dfc3 DRW: Retopology Overlay
Add overlay option for retopology, which hides the shaded mesh akin to Hidden Wire, and offsets the edit mesh overlay towards the view.

Related Task #70267
Pull Request #104599
2023-03-03 00:35:45 +01:00
Patrick Busch 5ea41a9942 UI: Added Edge Width option in preferences for 3DView and UV/Image Editor
Previously [D16255](https://developer.blender.org/D16255)
There is no option to adjust the edge_width like there is in the preferences for vertex_size and face_dot_size.

I only added the option for 3DView and UV/Image Editor, and limited both to a max size of 5 pixel, since the edges do not look very nice with too high values.
In the UV Editor only, there are always black outlines on the edges, I could not find a way to reduce the increasing thickness of these black outlines.

The default edge_width of 1 pixel:

![shows the marked new attribute with a value of 1 in the settings for the UV/Imageeditor](/attachments/f48fc1e5-2b49-4337-bd86-f2ad4aca42c3)

Here the edge_width with a falue of 3:

![shows the marked new attribute with a value of 3 in the settings for the UV/Imageeditor](/attachments/d0b0b1ea-5967-46b2-80a2-ccae18933638)

And here the visible increase of the dark border of the edges and their overlap (even at the maxed size of 5):

![shows the marked new attribute with a value of 5 in the settings for the UV/Imageeditor and points out the thicker border in the left side UV Editor](/attachments/1590965f-af2a-49d0-a11e-1afecaabf940)

Lastly for the 3DView the max edge_width of 5 looks like this:

![shows the marked new attribute with a value of 5 for the settings for the 3DView and it's resulting wider lines in the right side visible 3DView](/attachments/fcd35341-97a5-4db6-8bbf-c5ce5333e5aa)

Pull Request #104741
2023-02-27 20:02:37 +01:00
Sergey Sharybin 03806d0b67 Re-design of submodules used in blender.git
This commit implements described in the #104573.

The goal is to fix the confusion of the submodule hashes change, which are not
ideal for any of the supported git-module configuration (they are either always
visible causing confusion, or silently staged and committed, also causing
confusion).

This commit replaces submodules with a checkout of addons and addons_contrib,
covered by the .gitignore, and locale and developer tools are moved to the
main repository.

This also changes the paths:
- /release/scripts are moved to the /scripts
- /source/tools are moved to the /tools
- /release/datafiles/locale is moved to /locale

This is done to avoid conflicts when using bisect, and also allow buildbot to
automatically "recover" wgen building older or newer branches/patches.

Running `make update` will initialize the local checkout to the changed
repository configuration.

Another aspect of the change is that the make update will support Github style
of remote organization (origin remote pointing to thy fork, upstream remote
pointing to the upstream blender/blender.git).

Pull Request #104755
2023-02-21 16:39:58 +01:00
Damien Picard 2e19aa1399 UI: add camera passepartout color to theme
Currently the passepartout color is hardcoded to black. While a
sensible default for cinema, it may make less sense for other media,
whether video, print, web, etc. It greatly affects viewing conditions
of the image and should be user selectable, much like painting
programs allow.

Pull Request #104486
2023-02-13 09:15:34 +01:00
Julian Eisel 23d2e77a54 UI: Add initial "grid view"
Part of T98560.
See https://wiki.blender.org/wiki/Source/Interface/Views

Adds all the basic functionality needed for grid views. They display
items in a grid of rows and columns, typically with a preview image and
a label underneath. Think of the main region in the Asset Browser.

Current features:
- Active item
- Notifier listening (also added this to the tree view)
- Performance: Skip adding buttons that are not scrolled into view
  (solves performance problems for big asset libraries, for example).
- Custom item size
- Preview items (items that draw a preview with a label underneath)
- Margins between items scale so the entire region width is filled with
  column, rather than leaving a big empty block at the right if there's
  not enough space for another column (like the File and current Asset
Browser does it).
- "Data-View Item" theme colors. Not shown in the UI yet.

No user visible changes expected since the grid views aren't used for
anything yet.

This was developed as part of a rewrite of the Asset Browser UI
(`asset-browser-grid-view` branch), see T95653. There's no reason to
keep this part in a branch, continuing development in master makes
things easier.

Grid and tree views have a lot of very similar code, so I'm planning to
unify them to a degree. I kept things separate for the start to first
find out how much and what exactly makes sense to override.
2022-06-16 19:25:50 +02:00
Richard Antalik 277fa2f441 VSE: Add channel headers
This patch adds channel region to VSE timeline area for drawing channel
headers. It is synchronizedwith timeline region. 3 basic features are
implemented - channel visibility, locking and name.

Channel data is stored in `SeqTimelineChannel` which can be top-level
owned by `Editing`, or it is owned by meta strip to support nesting.
Strip properties are completely independent and channel properties are
applied on top of particular strip property, thus overriding it.

Implementation is separate from channel regions in other editors. This
is mainly because style and topology is quite different in VSE. But
also code seems to be much more readable this way.

Currently channels use functions similar to VSE timeline to draw
background to provide illusion of transparency, but only for background
and sfra/efra regions.

Great portion of this patch is change from using strip visibility and
lock status to include channel state - this is facilitated by functions
`SEQ_transform_is_locked` and `SEQ_render_is_muted`

Originally this included changes in D14263, but patch was split for
easier review.

Reviewed By: fsiddi, Severin

Differential Revision: https://developer.blender.org/D13836
2022-04-04 12:56:43 +02:00
Leon Schittek 2670032038 UI: Improve node editor dot background
This commit makes the dot grid used as background in the node editor
more visually stable when zooming in and out.

The dot grid now uses a continuously subdividing pattern, where
each level of subdivision divides the previous five times, similar to
the line grid in the 3D viewport.

The maximum for the "Grid Levels" theme setting is changed to 3, since
any further subdivisions are too small to be visible.
The "Grid Levels" value for the default themes "Blender Dark" and
"Blender Light" is therefore changed to 3, as well.

Reviewed By: Hans Goudey, Pablo Vazquez

Differential Revision: http://developer.blender.org/D13302
2022-03-30 21:21:57 +02:00
Campbell Barton 281ba8a063 File headers: add missing copyright, add MIT to SPDX licenses 2022-02-11 14:56:03 +11:00
Richard Antalik 61bffa565e Fix T90412: Inconsistency in mask strip color
This seems to be oversight in 271231f58e where strip color was
defined only for light theme.
2021-11-17 03:27:13 +01:00
Pablo Vazquez 81bee0e75a UI: Fix minor theme mismatch
Pie menu got wrong item highlight and options settings were outdated.
2021-11-05 19:20:47 +01:00
Pablo Vazquez e65230f0c0 UI: Various theme fixes related to contrast
* Animation channels (Fixes T92612)
* Curve widget (Fixes T92595)
* Pie menu (Fixes T92590)
* Radio and toggle buttons background
* Checkbox background
* Fix highlighted marker name on Dopesheet (text highlight on Dopesheet)


#### Master
{F11697667, size=full}

#### This Patch
{F11697669, size=full}
{F11697849, size=full}
{F11697833, size=full}
{F11697852, size=full}

Reviewed By: #user_interface, campbellbarton, Severin

Maniphest Tasks: T92595, T92612, T92590

Differential Revision: https://developer.blender.org/D13087

# Conflicts:
#	source/blender/blenkernel/BKE_blender_version.h
2021-11-05 15:06:37 +01:00
Pablo Vazquez b4af70563f VSE: Remove separator lines between rows
The VSE grid theme setting is currently used for two things:

* Indicate time intervals (vertical lines)
* As separator between channels (horizontal lines)

This adds visual noise because for the time interval to be visible, the
grid color needs to be bright, resulting in a rectangle-grid backdrop.

Recently, the VSE got a theme setting to customize alternate-row background color.
This should be sufficient to tell the channels apart without the need for a line in between.

Additionally, this patch makes the VSE background use the theme setting as-is,
without hard-coded darkening, to ease the tweaking of themes.  This aligns the style
of the VSE backdrop with the rest of Blender (Outliner rows, File Browser, Spreadsheet,
Info and animation editors).

Related reports: T92581
Related task: T92792

#### Before
{F11680317, size=full}

#### After
{F11694981, size=full}

Reviewed By: #user_interface, Severin

Maniphest Tasks: T92581

Differential Revision: https://developer.blender.org/D13072
2021-11-05 15:06:37 +01:00
Pablo Vazquez 9e71a07547 UI: Fix UIList item using "regular" widget colors while edited
Simply removing the check for `UI_STATE_TEXT_INPUT` makes it inherit
the "List Item" User Interface theme settings. This patch changes the
default theme to match the colors of text input fields.

#### Master
{F11680556, size=full}

#### This patch
{F11680557, size=full}

All the included commmunity themes seem to work well (only Deep Grey might
need more contrast but that's a different patch).

Related reports: T92720

Reviewed By: #user_interface, Severin

Maniphest Tasks: T92720

Differential Revision: https://developer.blender.org/D13073
2021-11-04 15:31:48 +01:00
Pablo Vazquez bfec984cf8 UI: Theme refresh for Blender v3.0
{F11548100, size=full}

To celebrate the beginning of a new series, it feels like the right time to
give the theme a fresh look while improving on what already works.

The aim of this refresh is to keep a familiar look but with polishing touches
here and there. Like new paint on the walls of your well known house.

The theme for Blender 2.8 was well received but presented a few flaws.

* Transparency on menus and tooltips reduce readability
* Mismatch on certain colors, especially outlines of connected widgets
* Active/open menus highlight was not prominent enough
* Header background mismatch in some editors

At the same time we can make use of new features in 3.0:

* Make panels look like panels again (like in v2.3!)
* Make use of roundness in more widgets
* Since nodes are no longer hard-coded to be transparent, tweak opacity and saturation
* Tweak colors for the new dot grid

This update does not include:

* Meshes in edit mode to match greenish object-data color. This needs tweaks in the code to improve contrast.
* A copy of the Blender 2.8x legacy theme. This could be added to the community themes (shouldn't cost much maintenance, I hope)

There will be certainly small tweaks to do here and there, I've been working using this theme
for months but there can be areas that are missing update. The overall style is presented here.

This commit bumps the file subversion.

Reviewed By: #user_interface, Severin

Differential Revision: https://developer.blender.org/D13008
2021-10-27 18:29:18 +02:00
Pablo Vazquez 4db4a97355 Node Editor: Style update to nodes
This patch changes how nodes look visually, in an attempt to fix a number of issues:
* The header background is currently drawn using a theme color fully opaque, this limits the colors we can use because the node name/label is drawn on top.
* Hard-coded transparency makes nodes hard to read. The node backdrop already has alpha so if the user wants it they can set it. This patch uses alpha from the theme.
* Better muted status indicator, instead of simply making everything transparent and the wires inside red, draw a red outline around the node, darken the header and backdrop.
* On muted nodes, display wires behind the backdrop to not interfere with text/widgets inside the node.

Nodes:

* Darken header to improve readability of node label.
* Draw a line under the header
* Thicker outline.
* Do not hard-code transparency on nodes, use the theme's node backdrop alpha component.
* Use angle icon instead of triangle (to be consistent with the [[ https://developer.blender.org/D12814 | changes ]] to panels)

Style adjustment to sockets drawing:

* Do not hard-code the socket outline color to black, use `TH_WIRE` instead
* Do not use `TH_TEXT_HI` for selected sockets, use `TH_ACTIVE` (active node outline)
* Do not draw sockets background transparent on muted nodes.
* Thicker outline to help contrast and readability

{F11496707, size=full}

Reviewed By: #user_interface, HooglyBoogly

Differential Revision: https://developer.blender.org/D12884
2021-10-26 20:19:24 +02:00
Hans Goudey e463d2c16f UI: Change node editor grid into a dot grid
This patch makes the background grid of the node editor a grid of dots
instead of lines. This makes the background look a bit more subtle and
reduces visual complexity. The dots are meant to provide a reference
when panning and zooming. Based on the design of @pablovazquez, and
a patch originally authored by @fabian_schempp.

The "Grid Levels" controls how many levels of dots are drawn. As the
editor zooms in, the higher levels of dots fade in, making them closer
together visually. The zoom factor at which each grid starts and ends
fading in is controllable in the code, and could be tweaked further
in the future. The new default value is 7, out of a range from 0 to 9.

Differential Revision: https://developer.blender.org/D10345
2021-10-25 21:50:05 -05:00
Pablo Vazquez 9b1b4b9e32 Node Editor: Introduce color overlay and dashed wires theme setting
This patch includes code from D9891 and D12754, so credit goes to Juanfran and Dalai.
I updated the patches to work with `master` and with the new overlay toggle.

The reason to include both changes as part of one patch is that the dimmed dashed lines work much better together with colored wires.

Theme setting for dash opacity:
{F11370574, size=full}

{F11286177, size=full, autoplay, loop}

{F11149912, size=full}

For adding the overlay I used `SpaceImageOverlay` as reference, although I'm not familiar with this code so there might be mistakes.

Reviewed By: #user_interface, HooglyBoogly

Differential Revision: https://developer.blender.org/D12886
2021-10-21 21:00:38 +02:00
Pablo Vazquez 93544b641b UI: Visual style update to panels
Back in Blender 2.30, the GUI project brought panels into Blender among other important visual updates.
For the first time it was possible to move the wall of buttons around. Providing a clear separation
between sections (it even allowed the grouping of panels in tabs!)

During the 2.5 redesign, the separation between panels became a line on top of each panel, and panels received
theme settings for background and header colors. The default theme used the same color for both.

In 2.8 the background color of panels was different from headers in the default theme, so the separator
line was removed. While the separator line wasn't elegant (only on top, non-themeable, hard-coded emboss effect),
it provided a sort of separation between panels.

This patch solves the panels-separation by simply adding a margin space around them (not visible in default theme yet).
Even though the margin reduces the width of the working area slightly, it makes room for the upcoming always-visible scrollbars.

Other adjustments:
* Use arrow icon instead of triangle to collapse/expand
* Use rounded corners to match the rest of the UI (editor corners, nodes, etc).

{F10953929, size=full}

Margin on panels makes use of the `style->panelouter` property that hasn't been
used in a while. Also slight tweaks to `boxspace` and `templatespace` style properties so they
are multiples of 2 and operations on them round better.

There is technically no need to update the themes for them to work, so no theme changes are included in this patch.

{F10953931, size=full}

{F10953933, size=full}

{F10953934, size=full}

{F10954003, size=full}

----

A new theme setting under Style controls the roundness of all panels (added it to Style instead of ThemeSpace because I think controlling the panel roundness per editor is a bit overkill):
{F11091561, size=full, autoplay, loop}

Reviewed By: HooglyBoogly

Differential Revision: https://developer.blender.org/D12814
2021-10-17 18:31:24 +02:00
Dalai Felinto ff9587d28e User Interface: Use theme alpha for the nodes frames background
This bump subversion.
2021-10-08 15:37:43 +02:00
Falk David 5cebcb415e VSE: Add color tags to strips
This patch adds color tags to VSE strips, an overlay option to toggle the colors
on and off, a section in the theme settings to define the 9 possible colors and
two ways of changing the color tag through the UI. You can change the color
through the right-click context menu, or in the strip side panel next to the
strip name.

Color tags are defined in user preferences and they can be disabled in overlay
settings.

Reviewed By: campbellbarton, ISS

Differential Revision: https://developer.blender.org/D12405
2021-09-29 14:34:01 +02:00
Dalai Felinto 4a0ddeb62b Nodes: Change wire color to increase contrast
If the theme used by the user did not touch the wire or the wire outline
colors this will update them as well.

This was supposed to be a part of a bigger UI theme change for 3.0. But
it was expedited because of the recent change in line thickness for the
noodles (2bd0205215).

Theme change by Pablo Vazquez.

Differential Revision: https://developer.blender.org/D12649
2021-09-27 16:09:40 +02:00
Richard Antalik 0491052a96 VSE: Change grid line drawing
Add overlay option to disable grid drawing.
Reuse drawing code from other editors (timeline editor)
Add argument `display_minor_lines` to function
`UI_view2d_draw_lines_x__discrete_frames_or_seconds`
This way minor line drawing can be disabled and so it doesn't cause
too much visual noise. Also spacing seems to be too fine, so VSE uses 3x
what is defined in preferences.

Reviewed By: fsiddi, Severin

Differential Revision: https://developer.blender.org/D11790
2021-07-29 11:38:43 +02:00
Fabian Schempp ae085e301c Spreadsheet: Dataset region for spreadsheet editor
This patch adds a left aligned sidebar to the spreadsheet editor. This
Sidebar can be used to navigate the geometry component types and
attribute domains. It also provides a quick overview of domain sizes.
It replaces the two dropdowns in the regions header.
Next step will be to add the domain cycling shortcut
using the CTRL + mouse wheel.

Reviewer: Dalai Felinto (dfelinto), Julian Eisel (Severin),
Hans Goudey (HooglyBoogly).

Differential Revision: https://developer.blender.org/D11046
2021-06-25 07:57:24 +02:00
Pablo Vazquez 01f028a677 Theme: Use curved noodles in the nodes editor.
Curved noodles increase readability especially in nodes with multiple input sockets.
2021-03-20 01:12:49 +01:00
Jacques Lucke 9cb5f0a228 Spreadsheet: add boilerplate code for new editor type
This adds the initial boilerplate code that is required to introduce
the new spreadsheet editor. The editor is still hidden from the ui.

It can be made visible by undoing the change in `rna_screen.c`.

This patch does not contain any business logic for the spreadsheet editor.

Differential Revision: https://developer.blender.org/D10645

Ref T86279.
2021-03-08 16:25:08 +01:00
Harley Acheson 694bc4d040 Fix for T84038: Improved Report Warnings
Improved contrast for Status Bar report warning messages.

Differential Revision: https://developer.blender.org/D10242

Reviewed by Hans Goudey
2021-02-08 08:19:23 -08:00
Hans Goudey 71cb6923f5 Fix T83988: Active modifier outline uses search theme color
The outline for the active modifier was abusing the property search
match theme color, as noted in a comment. This commit adds a new
theme color in RNA specifically for the active modifier outline.
2021-01-28 16:16:24 -06:00
Brecht Van Lommel 09fe0e8aa9 Nodes: use green color again for shader sockets and shader category
The green is still distinct from the more turquoise use for geometry, and
they are never used in the same node graph. The use of red makes sense, but
would need changes to other sockets and categories to set it apart well.

Ref T82689
2021-01-13 18:00:14 +01:00
Hans Goudey 9281a1f4eb UI: Add new node colors for geometry nodes
During the development of the new nodes in the `geometry-nodes` branch
the color of the new nodes wasn't considered, so all of the nodes ended
up red, the color for "input" nodes. This patch introduces two new
colors, one for "Geometry" and one for "Attributes". There are only two
attribute nodes currently, but the next sprint will add two more,
attribute mix, and sample from texture. The attribute nodes are
conceptually different enough from the nodes that modify the geometry
that they deserve their own color.

Differential Revision: https://developer.blender.org/D9682
2020-12-02 16:34:06 +01:00
Pablo Vazquez 8268b9827a Theme: update shader node color to match socket color
Reviewed by Brecht

Ref T82689.
2020-12-02 15:38:47 +01:00
Erik Abrahamsson f7223d5f72 UI: Allow theming the alternate row color in the sequencer
Previously, the alternate row color in the Video Sequence Editor was
just a shaded version of the editor's background color. This makes it
theme-able just like in the file browser and outliner, although the
default color is very slightly different.

Differential Revision: https://developer.blender.org/D9634
2020-11-25 16:37:33 -05:00
Nathan Craddock 1d4f3e2a26 Outliner: Collection icon color tweaks
The icons originally chosen for the collection colors were selected
during development and had a few issues with contrast in the light
theme, and the gray color was not a good choice against the default gray
backgrounds.

The new colors are more readable in both default Blender themes. Gray
was replaced with pink.

Differential Revision: https://developer.blender.org/D9504
2020-11-16 13:54:05 -07:00
Pablo Vazquez 4ee1332bdf Fix T79615: UI: icons and widget emboss look different from earlier versions
Both the default theme and Blender Light have been updated.

Blender Light also includes automatically generated colors based on the
default theme that were not set previously.
2020-10-08 16:17:31 +02:00
Hans Goudey 983ad4210b Fix T76595: Indicate the Active Keyframe in Graph Editor
In the graph editor there is a panel that says "Active Keyframe" for
numerically editing a keyframe's values, but in the code there is no
concept of the "active keyframe." Since this is a useful concept to
have for some other features anyway, this commit adds an active
keyframe index value to FCurves. It also displays it with a theme
color for the active vertex (which didn't exist before) if the
FCurve is active.

The active keyframe in the graph editor is treated similarly to the
active vertex in the 3D view. It is the keyframe most recently selected
with a single click, and it is always selected.

For now, the only real functional change is that the active keyframe
appears in white and it should be more predictable which keyframe is
being edited in the sidebar panel.

Differential Revision: https://developer.blender.org/D7737
2020-10-07 08:27:58 -05:00
Red Mser 675807e2b6 UI: Add grid-related theme options
This commit makes grid theming more consistent and capable by adding
some new theme colors related to grid rendering.
 - Add grid theme color for node editor. `UI_view2d_multi_grid_draw`
   is called with TH_GRID instead of a shaded `TH_BACK`.
   Also color-blend `TH_NODE_GROUP`.
 - Make the movie clip editor's clip preview grid respect grid theme
   color (`ED_region_grid_draw` uses color-blended `TH_GRID`).
 - Add versioning code to allow fixing existing themes (the resulting
   themes should visually look the same as before)

These changes did cause some inconsistencies in the movie clip editor,
even after adjusting the themes accordingly:
1. The alpha slider of the grid color affects the background and not
   the grid lines themselves.
2. The grids used by graph and dopesheet mode could already be themed
   in the past. Now that the clip preview's grid can also be themed,
   two different modes share the same theme color.

Differential Revision: https://developer.blender.org/D8699
2020-09-15 18:42:38 -05:00