Bug 456299 - Enclose-and-fill tool: Take image border into account
Summary: Enclose-and-fill tool: Take image border into account
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Usability (show other bugs)
Version: 5.1.0-beta1
Platform: Appimage Linux
: NOR wishlist
Target Milestone: ---
Assignee: Deif Lou
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-07-04 01:54 UTC by tomtomtomreportingin
Modified: 2022-07-07 15:03 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tomtomtomreportingin 2022-07-04 01:54:56 UTC
Reposting from https://krita-artists.org/t/enclose-and-fill-tool-proposal/31397/59 so that it's documented on the tracker.

Currently the enclose-and-fill tool doesn't see the image border as a boundary. This is a problem with probably quite a bit of lineart that trails off the canvas, and could also confuse users attempting to get the feature to work. I don't really see any practical usecase of having it ignore the image borders.
Comment 1 Deif Lou 2022-07-05 12:58:52 UTC
Yes, I didn't forget about that, and I agree with what you say. It's just that I haven't got much time lately.
Comment 2 Deif Lou 2022-07-05 13:02:00 UTC
The only practical case I can think of is when using the "wrap around mode", but since the "enclose and fill" uses the "floodfill" algorithm (which the "fill tool" uses as well), and it is not "wrap around mode" aware, I think we can skip that for now.
Comment 3 Bug Janitor Service 2022-07-06 16:06:17 UTC
A possibly relevant merge request was started @ https://invent.kde.org/graphics/krita/-/merge_requests/1506
Comment 4 Deif Lou 2022-07-07 14:51:38 UTC
Git commit 60b0d351cd5e2cb820ebd844c146d3a3644ff66c by Deif Lou.
Committed on 07/07/2022 at 14:34.
Pushed by deiflou into branch 'master'.

Make the enclose and fill tool take into account canvas limits.

Now, when the wrap around mode is not active, the canvas border is taken as
another limit when finding the regions

M  +52   -19   libs/image/KisEncloseAndFillPainter.cpp
M  +3    -3    libs/image/KisEncloseAndFillPainter.h
M  +1    -3    libs/ui/processing/KisEncloseAndFillProcessingVisitor.cpp

https://invent.kde.org/graphics/krita/commit/60b0d351cd5e2cb820ebd844c146d3a3644ff66c
Comment 5 Deif Lou 2022-07-07 15:03:19 UTC
Git commit c111c9f7765e432da792176271a716b8475483c5 by Deif Lou.
Committed on 07/07/2022 at 15:02.
Pushed by deiflou into branch 'krita/5.1'.

Make the enclose and fill tool take into account canvas limits.

Now, when the wrap around mode is not active, the canvas border is taken as
another limit when finding the regions

M  +52   -19   libs/image/KisEncloseAndFillPainter.cpp
M  +3    -3    libs/image/KisEncloseAndFillPainter.h
M  +1    -3    libs/ui/processing/KisEncloseAndFillProcessingVisitor.cpp

https://invent.kde.org/graphics/krita/commit/c111c9f7765e432da792176271a716b8475483c5