From 0590beb876bbccf245886033c638c5006469ea75 Mon Sep 17 00:00:00 2001 From: chrik5 Date: Tue, 24 Jan 2017 20:56:07 +0100 Subject: [PATCH] quicktag - add tags if they not exist in the taglist of darktable --- contrib/quicktag.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/contrib/quicktag.lua b/contrib/quicktag.lua index 6dc4e99..3ab7ded 100644 --- a/contrib/quicktag.lua +++ b/contrib/quicktag.lua @@ -36,7 +36,6 @@ USAGE TODO * enhance button and entry layout in the module - * option to add non existing tags * abbrevate button labels * maybe two colums of buttons ]] @@ -89,10 +88,11 @@ local function tagattach(tag,qtagnr) end local tagnr = dt.tags.find(tag) - + +--create tag if it does not exist if tagnr == nil then - dt.print("quick tag \""..tag.."\" not found in your taglist, please add it first!") - return true + dt.tags.create(tag) + tagnr = dt.tags.find(tag) end local sel_images = dt.gui.action_images