Skip to content

Conversation

@Photon89
Copy link
Member

@Photon89 Photon89 commented Jan 4, 2026

For the moment there is just a fixed variable $dark_icons which controls which custom icon set is used. To do:

  • Set icon choice from a system setting.
  • Implement automatic background detection.
  • Better handling of duplicate icons via symlinks.

@Photon89 Photon89 linked an issue Jan 4, 2026 that may be closed by this pull request
bin/shutter Outdated
);
}

our $dark_icons = 1;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
our $dark_icons = 1;
my $dark_icons = 1;

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It spit errors with "my":

Global symbol "$dark_icons" requires explicit package name (did you forget to declare "my $dark_icons"?) at ./bin/shutter line 6020.
Execution of ./bin/shutter aborted due to compilation errors.
 at ./bin/shutter line 11118.

But the variable needs to be defined elsewhere anyway, I just put it there for a quick test.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Never mind, the reason for the error was elsewhere, "my" also works. I will change it while putting the variable to a more sensible place.

@Photon89
Copy link
Member Author

Photon89 commented Jan 4, 2026

I added the radio buttons. For now the "auto" option is dysfunctional. The icons are set at Drawing Tool launch.

@Photon89
Copy link
Member Author

Photon89 commented Jan 4, 2026

The automatic detection seems to work really well! But I think that the menu option is still necessary for cases when it fails.

Now I wonder what is the fastest way to create a lot of symlinks. The contents of /share/shutter/resources/icons/drawing_tool and /share/shutter/resources/icons/drawing_tool_dark are almost identical, only five icons differ.

@DarthGandalf
Copy link
Member

A for loop in zsh? :)

Or reading the icon could check one dir first, and if file doesn't exist read the other dir

@DarthGandalf
Copy link
Member

Rather than passing 3 new bool parameters, let's pass only 1, then do the coloring depending on the value passed there

@Photon89 Photon89 marked this pull request as ready for review January 4, 2026 15:45
@Photon89
Copy link
Member Author

Photon89 commented Jan 4, 2026

Okay, should be fine now, please have a look!

@Photon89
Copy link
Member Author

Photon89 commented Jan 4, 2026

Rather than passing 3 new bool parameters, let's pass only 1, then do the coloring depending on the value passed there

Sorry, missed this one. I will have a look into it.

@Photon89
Copy link
Member Author

Photon89 commented Jan 4, 2026

Better this way?

@Photon89 Photon89 changed the title Work on custom icon adjustment in Drawing Tool started Custom icon adjustment in Drawing Tool Jan 4, 2026
@Photon89 Photon89 merged commit f6c046e into master Jan 4, 2026
1 check passed
@Photon89 Photon89 deleted the draw-dark branch January 4, 2026 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

In Edit, can't make out most icons on dark theme and high res screen

3 participants