[evince] annotations: Add icons for squiggly and text annotations
- From: Germán Poo-Caamaño <gpoo src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evince] annotations: Add icons for squiggly and text annotations
- Date: Mon, 12 Nov 2018 03:54:08 +0000 (UTC)
commit 85aacdaf4dadb4808acaa8fcd1d8c2859e7a8d95
Author: Germán Poo-Caamaño <gpoo gnome org>
Date: Mon Nov 12 00:06:13 2018 -0300
annotations: Add icons for squiggly and text annotations
data/icons/meson.build | 2 +
data/icons/scalable/actions/Makefile.am | 2 +
.../actions/annotations-squiggly-symbolic.svg | 74 +++++++++++++
.../scalable/actions/annotations-text-symbolic.svg | 114 +++++++++++++++++++++
libview/ev-stock-icons.c | 8 +-
libview/ev-stock-icons.h | 2 +
shell/ev-sidebar-annotations.c | 9 +-
7 files changed, 202 insertions(+), 9 deletions(-)
---
diff --git a/data/icons/meson.build b/data/icons/meson.build
index f50c7e64..e00b5105 100644
--- a/data/icons/meson.build
+++ b/data/icons/meson.build
@@ -60,6 +60,8 @@ icons += [['48x48', actions, [], [ev_namespace + '.png']]]
icons += [['256x256', [], [], [ev_namespace + '.png']]]
actions = [
+ 'annotations-text-symbolic.svg',
+ 'annotations-squiggly-symbolic.svg',
'find-unsupported-symbolic.svg',
'object-rotate-left.svg',
'object-rotate-right.svg',
diff --git a/data/icons/scalable/actions/Makefile.am b/data/icons/scalable/actions/Makefile.am
index 338832e4..550e7c4b 100644
--- a/data/icons/scalable/actions/Makefile.am
+++ b/data/icons/scalable/actions/Makefile.am
@@ -5,6 +5,8 @@ context = actions
iconsdir = $(themedir)/$(size)/$(context)
icons_DATA = \
+ annotations-text-symbolic.svg \
+ annotations-squiggly-symbolic.svg \
find-unsupported-symbolic.svg \
object-rotate-left.svg \
object-rotate-right.svg \
diff --git a/data/icons/scalable/actions/annotations-squiggly-symbolic.svg
b/data/icons/scalable/actions/annotations-squiggly-symbolic.svg
new file mode 100644
index 00000000..bcf7d589
--- /dev/null
+++ b/data/icons/scalable/actions/annotations-squiggly-symbolic.svg
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="16"
+ height="16"
+ version="1.1"
+ id="svg878"
+ sodipodi:docname="format-text-underline-symbolic.svg"
+ inkscape:version="0.92.3 (2405546, 2018-03-11)">
+ <metadata
+ id="metadata884">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <defs
+ id="defs882" />
+ <sodipodi:namedview
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1359"
+ inkscape:window-height="835"
+ id="namedview880"
+ showgrid="false"
+ showguides="true"
+ inkscape:guide-bbox="true"
+ inkscape:zoom="41.7193"
+ inkscape:cx="7.818241"
+ inkscape:cy="5.5963852"
+ inkscape:window-x="388"
+ inkscape:window-y="139"
+ inkscape:window-maximized="0"
+ inkscape:current-layer="svg878">
+ <sodipodi:guide
+ position="5.7767029,2.9962152"
+ orientation="0,1"
+ id="guide1437"
+ inkscape:locked="false" />
+ </sodipodi:namedview>
+ <g
+ id="g1564">
+ <path
+ d="m 4,2 v 2 h 6 c 0.428,0 1,0.614 1,1 V 6 H 6 C 5.08,6 4.264,6.38 3.75,6.965 A 3.037,3.037 0 0 0
3.013,9.01 C 3.019,9.73 3.259,10.459 3.771,11.037 4.284,11.616 5.091,12 6,12 h 7 V 5 A 3,3 0 0 0 10,2 Z m 2,6
h 5 v 2 H 6 C 5.602,10 5.421,9.884 5.27,9.713 A 1.138,1.138 0 0 1 5.013,8.99 C 5.011,8.71 5.106,8.45
5.252,8.285 5.397,8.12 5.577,8 6,8 Z"
+ overflow="visible"
+
style="font-weight:400;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;text-transform:none;text-orientation:mixed;white-space:normal;shape-padding:0;overflow:visible;isolation:auto;mix-blend-mode:normal;"
+ id="path872"
+ inkscape:connector-curvature="0" />
+ <path
+ sodipodi:nodetypes="ccccccccccccccccc"
+ id="path851"
+
style="font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;text-transform:none;text-orientation:mixed;shape-padding:0;overflow:visible;isolation:auto;mix-blend-mode:normal;fill-opacity:1;stroke-width:0.72003782"
+ overflow="visible"
+ d="m 4.0049985,13 -1.8806418,1.526978 c -0.3770871,0.306304 0.1885435,0.765761 0.5656305,0.459457 l
1.3150113,-1.06882 1.5978269,1.297899 1.5978266,-1.297899 1.5978268,1.297899 1.5978262,-1.297899
1.597827,1.297899 1.880642,-1.526978 C 14.251861,13.382232 13.68623,12.922775 13.309143,13.229079 L
11.994132,14.297899 10.396305,13 8.7984788,14.297899 7.200652,13 5.6028255,14.297899 Z"
+ inkscape:connector-curvature="0" />
+ </g>
+</svg>
diff --git a/data/icons/scalable/actions/annotations-text-symbolic.svg
b/data/icons/scalable/actions/annotations-text-symbolic.svg
new file mode 100644
index 00000000..c17afefb
--- /dev/null
+++ b/data/icons/scalable/actions/annotations-text-symbolic.svg
@@ -0,0 +1,114 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="16"
+ height="16"
+ version="1.1"
+ id="svg1972"
+ sodipodi:docname="annotations-text-symbolic.svg"
+ inkscape:version="0.92.3 (2405546, 2018-03-11)">
+ <metadata
+ id="metadata1978">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <defs
+ id="defs1976" />
+ <sodipodi:namedview
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1920"
+ inkscape:window-height="1016"
+ id="namedview1974"
+ showgrid="false"
+ showguides="true"
+ inkscape:guide-bbox="true"
+ inkscape:zoom="41.7193"
+ inkscape:cx="5.9814254"
+ inkscape:cy="7.0463535"
+ inkscape:window-x="0"
+ inkscape:window-y="27"
+ inkscape:window-maximized="1"
+ inkscape:current-layer="svg1972">
+ <sodipodi:guide
+ position="2.6366694,7.5264925"
+ orientation="0,1"
+ id="guide2538"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="7.3826742,3.0201849"
+ orientation="0,1"
+ id="guide2540"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="-11.649285,9.3721611"
+ orientation="1,0"
+ id="guide2542"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="3.4276702,13.902438"
+ orientation="1,0"
+ id="guide2546"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="-0.57527331,19.151807"
+ orientation="0,1"
+ id="guide3165"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="2.4688813,5.5130359"
+ orientation="0,1"
+ id="guide3167"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="-5.4411268,9.5878886"
+ orientation="0,1"
+ id="guide3313"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="8.5092511,12.823801"
+ orientation="1,0"
+ id="guide3315"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="-0.6711522,1.5100924"
+ orientation="0,1"
+ id="guide3317"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="-1.030698,3.4995793"
+ orientation="0,1"
+ id="guide3319"
+ inkscape:locked="false" />
+ <sodipodi:guide
+ position="12.00883,13.854499"
+ orientation="1,0"
+ id="guide3321"
+ inkscape:locked="false" />
+ </sodipodi:namedview>
+ <path
+ d="m 14.534063,3.9503791 c 0,-1.3818613 -1.094802,-2.502772 -2.47666,-2.5 H 4.0738029 c -1.385,0
-2.5119848,1.1150001 -2.5119848,2.5 v 6.1154849 c 0,1.385 1.1030151,2.449 2.4880151,2.469 H 9.385721 l
3.125,3.273378 v -3.273378 c 1.162733,-0.23178 2.023327,-1.283391 2.023342,-2.469 z M 12.464255,7.7783856 V
9.7918421 H 3.4276702 V 7.7783856 Z M 8.4470192,3.7994121 8.4709889,5.70101 h -5.019349 l -0.02397,-1.9015979
z"
+ id="path1970"
+ style="opacity:0.98000004"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="scssscccccscccccccccc" />
+</svg>
diff --git a/libview/ev-stock-icons.c b/libview/ev-stock-icons.c
index fa53acf4..0f780d88 100644
--- a/libview/ev-stock-icons.c
+++ b/libview/ev-stock-icons.c
@@ -1,10 +1,8 @@
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
/* Stock icons for Evince
*
- * Copyright (C) 2003 Martin Kretzschmar
- *
- * Author:
- * Martin Kretzschmar <Martin Kretzschmar inf tu-dresden de>
+ * Copyright (C) 2003 Martin Kretzschmar <Martin Kretzschmar inf tu-dresden de>
+ * Copyright (C) 2018 Germán Poo-Caamaño <gpoo gnome org>
*
* Evince is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by
@@ -34,6 +32,8 @@ typedef struct {
/* Evince stock icons */
static const EvStockIcon stock_icons [] = {
+ { EV_STOCK_ANNOT_TEXT, "annotation-text-symbolic" },
+ { EV_STOCK_ANNOT_SQUIGGLY, "annotation-squiggly-symbolic" },
{ EV_STOCK_FIND_UNSUPPORTED, "find-unsupported-symbolic" },
{ EV_STOCK_ZOOM, "zoom" },
{ EV_STOCK_ZOOM_PAGE, "zoom-fit-height" },
diff --git a/libview/ev-stock-icons.h b/libview/ev-stock-icons.h
index 15f706a9..70c4a5d1 100644
--- a/libview/ev-stock-icons.h
+++ b/libview/ev-stock-icons.h
@@ -33,6 +33,8 @@
G_BEGIN_DECLS
/* Evince stock icons */
+#define EV_STOCK_ANNOT_TEXT "annotations-text-symbolic"
+#define EV_STOCK_ANNOT_SQUIGGLY "annotations-squiggly-symbolic"
#define EV_STOCK_FIND_UNSUPPORTED "find-unsupported-symbolic"
#define EV_STOCK_ZOOM "zoom"
#define EV_STOCK_ZOOM_PAGE "zoom-fit-height"
diff --git a/shell/ev-sidebar-annotations.c b/shell/ev-sidebar-annotations.c
index 1e7b6efb..05de7340 100644
--- a/shell/ev-sidebar-annotations.c
+++ b/shell/ev-sidebar-annotations.c
@@ -429,9 +429,8 @@ job_finished_callback (EvJobAnnots *job,
if (EV_IS_ANNOTATION_TEXT (annot)) {
if (!text_icon) {
- /* FIXME: use a better icon than EDIT */
text_icon = gtk_icon_theme_load_icon (icon_theme,
-
"accessories-text-editor-symbolic",
+ EV_STOCK_ANNOT_TEXT,
ANNOT_ICON_SIZE,
0, NULL);
}
@@ -478,9 +477,9 @@ job_finished_callback (EvJobAnnots *job,
case EV_ANNOTATION_TEXT_MARKUP_SQUIGGLY:
if (!squiggly_icon) {
squiggly_icon = gtk_icon_theme_load_icon (icon_theme,
-
"tools-check-spelling-symbolic",
- ANNOT_ICON_SIZE,
- 0, NULL);
+
EV_STOCK_ANNOT_SQUIGGLY,
+ ANNOT_ICON_SIZE,
+ 0, NULL);
}
pixbuf = squiggly_icon;
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]