[gnumeric] GUI: Attach vertical alignment selector to the format toolbar.
- From: Morten Welinder <mortenw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnumeric] GUI: Attach vertical alignment selector to the format toolbar.
- Date: Thu, 20 Jan 2022 23:18:20 +0000 (UTC)
commit 348fa459fab3459f47ab61a167a30cbd09b6c346
Author: Morten Welinder <terra gnome org>
Date: Thu Jan 20 18:17:30 2022 -0500
GUI: Attach vertical alignment selector to the format toolbar.
And add some icons for it.
NEWS | 3 +++
icons/24x24/actions/Makefile.am | 4 ++++
icons/24x24/actions/gnumeric-format-valign-bottom.png | Bin 0 -> 2892 bytes
icons/24x24/actions/gnumeric-format-valign-center.png | Bin 0 -> 2892 bytes
icons/24x24/actions/gnumeric-format-valign-justify.png | Bin 0 -> 2892 bytes
icons/24x24/actions/gnumeric-format-valign-top.png | Bin 0 -> 2892 bytes
src/GNOME_Gnumeric-gtk.xml | 2 ++
src/gnm.gresource.xml | 4 ++++
src/wbc-gtk-actions.c | 13 ++++++++-----
9 files changed, 21 insertions(+), 5 deletions(-)
---
diff --git a/NEWS b/NEWS
index 53f08dfa5..61ae5641e 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,8 @@
Gnumeric 1.12.52
+Morten:
+ * Attach the vertical alignment selector to the toolbar.
+
--------------------------------------------------------------------------
Gnumeric 1.12.51
diff --git a/icons/24x24/actions/Makefile.am b/icons/24x24/actions/Makefile.am
index 078586418..dc92eb763 100644
--- a/icons/24x24/actions/Makefile.am
+++ b/icons/24x24/actions/Makefile.am
@@ -41,6 +41,10 @@ internalicons = \
gnumeric-format-precision-decrease.png \
gnumeric-format-precision-increase.png \
gnumeric-format-thousand-separator.png \
+ gnumeric-format-valign-bottom.png \
+ gnumeric-format-valign-center.png \
+ gnumeric-format-valign-justify.png \
+ gnumeric-format-valign-top.png \
gnumeric-formulaguru.png \
gnumeric-graphguru.png \
gnumeric-group.png \
diff --git a/icons/24x24/actions/gnumeric-format-valign-bottom.png
b/icons/24x24/actions/gnumeric-format-valign-bottom.png
new file mode 100644
index 000000000..dbdee26c1
Binary files /dev/null and b/icons/24x24/actions/gnumeric-format-valign-bottom.png differ
diff --git a/icons/24x24/actions/gnumeric-format-valign-center.png
b/icons/24x24/actions/gnumeric-format-valign-center.png
new file mode 100644
index 000000000..18151cc28
Binary files /dev/null and b/icons/24x24/actions/gnumeric-format-valign-center.png differ
diff --git a/icons/24x24/actions/gnumeric-format-valign-justify.png
b/icons/24x24/actions/gnumeric-format-valign-justify.png
new file mode 100644
index 000000000..1c33bb0d7
Binary files /dev/null and b/icons/24x24/actions/gnumeric-format-valign-justify.png differ
diff --git a/icons/24x24/actions/gnumeric-format-valign-top.png
b/icons/24x24/actions/gnumeric-format-valign-top.png
new file mode 100644
index 000000000..36bc79453
Binary files /dev/null and b/icons/24x24/actions/gnumeric-format-valign-top.png differ
diff --git a/src/GNOME_Gnumeric-gtk.xml b/src/GNOME_Gnumeric-gtk.xml
index bfb0bf1cc..fd9a0a38f 100644
--- a/src/GNOME_Gnumeric-gtk.xml
+++ b/src/GNOME_Gnumeric-gtk.xml
@@ -371,6 +371,8 @@
<toolitem action="CenterAcrossSelection"/>
<toolitem action="FormatMergeCells"/>
<toolitem action="FormatUnmergeCells"/>
+ <!-- Just a selector for vertical alignment. -->
+ <toolitem action="VAlignmentSelector"/>
<separator/>
<toolitem action="FormatAsAccounting"/>
<toolitem action="FormatAsPercentage"/>
diff --git a/src/gnm.gresource.xml b/src/gnm.gresource.xml
index 47e4b0379..883addfaf 100644
--- a/src/gnm.gresource.xml
+++ b/src/gnm.gresource.xml
@@ -118,6 +118,10 @@
<file>icons/24x24/actions/gnumeric-format-precision-decrease.png</file>
<file>icons/24x24/actions/gnumeric-format-precision-increase.png</file>
<file>icons/24x24/actions/gnumeric-format-thousand-separator.png</file>
+ <file>icons/24x24/actions/gnumeric-format-valign-bottom.png</file>
+ <file>icons/24x24/actions/gnumeric-format-valign-center.png</file>
+ <file>icons/24x24/actions/gnumeric-format-valign-justify.png</file>
+ <file>icons/24x24/actions/gnumeric-format-valign-top.png</file>
<file>icons/24x24/actions/gnumeric-formulaguru.png</file>
<file>icons/24x24/actions/gnumeric-graphguru.png</file>
<file>icons/24x24/actions/gnumeric-group.png</file>
diff --git a/src/wbc-gtk-actions.c b/src/wbc-gtk-actions.c
index dc9704ccc..3a0f9e766 100644
--- a/src/wbc-gtk-actions.c
+++ b/src/wbc-gtk-actions.c
@@ -3610,20 +3610,22 @@ static GnmActionEntry const actions[] = {
#warning "Add justify"
#warning "h/v distributed?"
-#warning "Get vertical alignment icons"
{ .name = "AlignTop",
+ .icon = "gnumeric-format-valign-top",
.toggle = TRUE,
.label = N_("Align _Top"),
.tooltip = N_("Align Top"),
.callback = G_CALLBACK (cb_align_top)
},
{ .name = "AlignVCenter",
+ .icon = "gnumeric-format-valign-center",
.toggle = TRUE,
.label = N_("_Vertically Center"),
.tooltip = N_("Vertically Center"),
.callback = G_CALLBACK (cb_align_vcenter)
},
{ .name = "AlignBottom",
+ .icon = "gnumeric-format-valign-bottom",
.toggle = TRUE,
.label = N_("Align _Bottom"),
.tooltip = N_("Align Bottom"),
@@ -3718,11 +3720,12 @@ static GOActionComboPixmapsElement const halignment_combo_info[] = {
{ NULL, NULL }
};
static GOActionComboPixmapsElement const valignment_combo_info[] = {
- { N_("Align top"), "gnumeric-format-valign-top", GNM_VALIGN_TOP },
+ { N_("Align top"), "gnumeric-format-valign-top", GNM_VALIGN_TOP },
{ N_("Center vertically"), "gnumeric-format-valign-center", GNM_VALIGN_CENTER },
- { N_("Align bottom"), "gnumeric-format-valign-bottom", GNM_VALIGN_BOTTOM },
- { N_("Justify"), "gnumeric-format-valign-justify", GNM_VALIGN_JUSTIFY },
- { N_("Align distributed"), "gnumeric-format-valign-distributed",
GNM_VALIGN_DISTRIBUTED },
+ { N_("Align bottom"), "gnumeric-format-valign-bottom", GNM_VALIGN_BOTTOM },
+ { N_("Justify"), "gnumeric-format-valign-justify", GNM_VALIGN_JUSTIFY },
+ // Reuse "center" icon as I don't know what this one is
+ { N_("Align distributed"), "gnumeric-format-valign-center", GNM_VALIGN_DISTRIBUTED },
{ NULL, NULL}
};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]