Bug 285826

Summary: Unable to edit Ingredients
Product: [Applications] krecipes Reporter: tbohaning
Component: generalAssignee: Unassigned bugs mailing-list <unassigned-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: lueck, panfaust
Priority: NOR    
Version: 2.0-beta2   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In: 2.2
Sentry Crash Report:

Description tbohaning 2011-11-05 15:36:04 UTC
Version:           2.0-beta2 (using Devel) 
OS:                Linux

One I create an ingredient, it's not possible to go back and edit it. The only way to fix it is to delete and recreate it. This makes it difficult for me to create standard naming in my recipes without a lot of work

Reproducible: Didn't try

Steps to Reproduce:
After creating a new ingredient try to change the name.

Actual Results:  
Editing not possible.

Expected Results:  
It would be good if the field could be edited...
Comment 1 Burkhard Lück 2014-11-11 06:58:31 UTC
(In reply to tbohaning from comment #0)
> Version:           2.0-beta2 (using Devel) 
> OS:                Linux
> 
> One I create an ingredient, it's not possible to go back and edit it. The
> only way to fix it is to delete and recreate it. This makes it difficult for
> me to create standard naming in my recipes without a lot of work
> 
> Reproducible: Didn't try
> 
> Steps to Reproduce:
> After creating a new ingredient try to change the name.
> 
> Actual Results:  
> Editing not possible.
> 
> Expected Results:  
> It would be good if the field could be edited...

You can edit the field.

Either click with the right mouse button and select "Rename" from the context menu or double click an an item and edit the name inline.

This information is also available in the chapter "The Ingredients Component" in the handbook, please read https://docs.kde.org/stable/en/extragear-utils/krecipes
Comment 2 José Manuel Santamaría Lema 2016-03-01 18:56:50 UTC
I think the reporter is talking about renaming/editing an ingredient when editing a recipe, which indeed it's not possible with krecipes up to 2.1, therefore I think the bug is valid.

A new ingredient editor for 2.2 is being worked on, in this new editor it will be possible to edit/rename the ingredients of a recipe.
Comment 3 José Manuel Santamaría Lema 2016-03-01 18:58:42 UTC
Git commit 58a8623fef4492f8d2e0a88204731668ae685d28 by José Manuel Santamaría Lema.
Committed on 01/03/2016 at 18:45.
Pushed by joselema into branch 'master'.

IngredientsEditor - code to handle ingredient name editing.

M  +1    -0    src/CMakeLists.txt
A  +93   -0    src/dialogs/recipeinput/ingredientnamedelegate.cpp     [License: GPL (v2+)]
A  +43   -0    src/dialogs/recipeinput/ingredientnamedelegate.h     [License: GPL (v2+)]
M  +29   -10   src/dialogs/recipeinput/ingredientseditor.cpp
M  +4    -0    src/dialogs/recipeinput/ingredientseditor.h
M  +1    -0    src/dialogs/recipeinput/recipeinputdialog.cpp

http://commits.kde.org/krecipes/58a8623fef4492f8d2e0a88204731668ae685d28
Comment 4 José Manuel Santamaría Lema 2016-04-01 13:27:33 UTC
Git commit 021976224c167003032e4af08df88369411275f2 by José Manuel Santamaría Lema.
Committed on 01/04/2016 at 11:01.
Pushed by joselema into branch 'master'.

Set the new editor as default.

There are still things to be implemented/fixed in the new editor but it's
good enough for git/master.
Related: bug 289334
FIXED-IN: 2.2

M  +4    -4    src/dialogs/recipeinput/recipeinputdialog.cpp

http://commits.kde.org/krecipes/021976224c167003032e4af08df88369411275f2