darktable icon indicating copy to clipboard operation
darktable copied to clipboard

Remove history item from the top

Open jcubic opened this issue 3 months ago • 17 comments

Is your feature request related to a problem? Please describe.

I have a photo with history where there is crop module. I edited the post to add more crop, another crop into history. I cloned the photo and I want to have the original before the crop and the one with double crop side by side.

But it seems that is no way to remove the item from the top of the history. You can move the history by clicking it, but the thumbnail shows the top. So now I have two identical photos with two crop module applied. And no way to restore the original photo with one crop.

Describe the solution you'd like

I assume that the history is the stack. Why not add a feature to remove the items from the top of the stack. Like, you select the given item in history and remove (discard) the items above.

Alternatives An alternative feature is a real Undo. It can be undo of history items, not undo of the action the user made (that's probably not feasible). So it may be a bit confusing.

Additional context

Let me know if this was discussed before and if it's doable in a near future.

jcubic avatar Sep 21 '25 19:09 jcubic

Just click on the history stack entry below the top one, then compress the stack (or not)

wpferguson avatar Sep 21 '25 19:09 wpferguson

If I compress the stack, I will lose the history. If you click on the stack history below, the thumbnail is not updated.

jcubic avatar Sep 21 '25 21:09 jcubic

The thumbnail doesn't update while you are editing. It will update when you exit darkroom and return to lighttable.

wpferguson avatar Sep 21 '25 23:09 wpferguson

It doesn't. The thumbnail in lighttable for both images is the same.

jcubic avatar Sep 22 '25 07:09 jcubic

@jcubic you were talking about being in lighttable while I was talking about being in darkroom.

If you duplicate the image in darkroom, then switch to it, you can click below the crop module you want to remove.

Blindly removing the top history stack entry in lighttable is not a good idea. It's an edit an should be done in darkroom so you know what you're removing.

wpferguson avatar Sep 22 '25 15:09 wpferguson

Let me be clear, becausae it seems to be misunderstanding.

The duplication happens on lighttable, and changing the history in darkroom don't affect lightable. What I propose is to in Darkroom discard what is above, what you select on the history list. Not top of the stack in lightable where you don't see the history, that would be silly.

jcubic avatar Sep 22 '25 16:09 jcubic

  • Jakub T. Jankiewicz @.***> [09-22-25 12:22]:

jcubic left a comment (darktable-org/darktable#19398)

Let me be clear, becausae it seems to be misunderstanding.

The duplication happens on lighttable, and changing the history in darkroom don't affect lightable. What I propose is to in Darkroom discard what is above, what you select on the history list. Not top of the stack in lightable where you don't see the history, that would be silly.

if clicking on an entry in the history stack deletes actions above it, it will interfer with many users who click on entries to see the effect of actions above the clicked item.

-- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri facebook/ptilopteri Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet oftc

ptilopteri avatar Sep 22 '25 16:09 ptilopteri

So you want to truncate the history stack (only remove what's above the selection, but not compress the steps below the selection)?

wpferguson avatar Sep 22 '25 16:09 wpferguson

@wpferguson Exactly.

@ptilopteri I'm not talking about deleting by clicking the history item, that would be absurd. I'm talking about an option to delete what is above selection, like you have with compress history and reset.

jcubic avatar Sep 22 '25 17:09 jcubic

  • Jakub T. Jankiewicz @.***> [09-22-25 13:25]:

jcubic left a comment (darktable-org/darktable#19398)

@wpferguson Exactly.

@ptilopteri I'm not talking about deleting by clicking the history item, that would be absurd. I'm talking about an option to delete what is above selection, like you have with compress history and reset.

well, will backtrack from the latest entry one step at a time.

-- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri facebook/ptilopteri Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet oftc

ptilopteri avatar Sep 22 '25 17:09 ptilopteri

Oh, didn't know there is a CTRL+Z shortcut. But it doesn't work, maybe because I'm not in the same session that added the changes. History don't change.

jcubic avatar Sep 22 '25 18:09 jcubic

  • Jakub T. Jankiewicz @.***> [09-22-25 14:27]:

jcubic left a comment (darktable-org/darktable#19398)

Oh, didn't know there is a CTRL+Z shortcut. But it doesn't work, maybe because I'm not in the same session that added the changes. History don't change.

correct, afaik, only works for actions is current session

-- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri facebook/ptilopteri Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet oftc

ptilopteri avatar Sep 22 '25 18:09 ptilopteri

As a workaround, you can select the history step you want, activate a module, deactivate this module ... then the top oh the history has disappeared, you just have a step above with a deactivated module .

nicor2012 avatar Sep 26 '25 08:09 nicor2012

Finally found a perfect answer :

  • click the history step you want
  • take a snapshot
  • then click the "downward arrow" aside the snapshot you want.
  • that's it : history is reverted to the choosen step without compression of previous steps and above history is deleted

nicor2012 avatar Oct 05 '25 16:10 nicor2012

  • nicor2012 @.***> [10-05-25 12:43]:

nicor2012 left a comment (darktable-org/darktable#19398)

Finally found a perfect answer :

  • click the history step you want
  • take a snapshot
  • then click the "downward arrow" aside the snapshot you want.
  • that's it : history is reverted to the choosen step without compression of previous steps and above history is deleted

or make a no-op module, select the next-to-last history item and initiante the no-op

-- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri facebook/ptilopteri Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet oftc

ptilopteri avatar Oct 05 '25 17:10 ptilopteri

@nicor2012 Your solution works great. But still it's hard to find, so maybe it would be beneficial to the same flow, but with one button with a clear name that is well documented.

But if you want to close the issue, go ahead.

jcubic avatar Oct 06 '25 13:10 jcubic

This issue has been marked as stale due to inactivity for the last 60 days. It will be automatically closed in 300 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.

github-actions[bot] avatar Dec 06 '25 00:12 github-actions[bot]