// SPDX-License-Identifier: GPL-2.0-or-later /** @file * @brief A dialog for CSS styles */ /* Authors: * Kamalpreet Kaur Grewal * Tavmjong Bah * Jabiertxof * * Copyright (C) Kamalpreet Kaur Grewal 2016 * Copyright (C) Tavmjong Bah 2017 * * Released under GNU GPL v2+, read the file 'COPYING' for more information. */ #include "styledialog.h" #include "attribute-rel-svg.h" #include "attributes.h" #include "document-undo.h" #include "inkscape.h" #include "io/resource.h" #include "selection.h" #include "style-internal.h" #include "style.h" #include "svg/svg-color.h" #include "ui/icon-loader.h" #include "ui/widget/iconrenderer.h" #include "verbs.h" #include "xml/attribute-record.h" #include "xml/node-observer.h" #include "xml/sp-css-attr.h" #include #include #include #include #include // G_MESSAGES_DEBUG=DEBUG_STYLEDIALOG gdb ./inkscape // #define DEBUG_STYLEDIALOG // #define G_LOG_DOMAIN "STYLEDIALOG" using Inkscape::DocumentUndo; using Inkscape::Util::List; using Inkscape::XML::AttributeRecord; /** * This macro is used to remove spaces around selectors or any strings when * parsing is done to update XML style element or row labels in this dialog. */ #define REMOVE_SPACES(x) \ x.erase(0, x.find_first_not_of(' ')); \ x.erase(x.find_last_not_of(' ') + 1); namespace Inkscape { /** * Get the first