[libshumate] marker: Remove global selection color variables
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libshumate] marker: Remove global selection color variables
- Date: Wed, 12 May 2021 21:02:28 +0000 (UTC)
commit eb46a13128bbb7f1908a204f4d926250d793ed72
Author: James Westman <james jwestman net>
Date: Wed May 12 12:55:11 2021 -0500
marker: Remove global selection color variables
ShumateMarker no longer draws any selection color--it's just a container
for other widgets. Besides, global variables wouldn't be a good way to
do this anyway. We could get the selection color from the GTK theme if
we needed.
Fixes #19.
docs/reference/libshumate-sections.txt | 4 ---
shumate/shumate-marker.c | 66 ----------------------------------
shumate/shumate-marker.h | 6 ----
3 files changed, 76 deletions(-)
---
diff --git a/docs/reference/libshumate-sections.txt b/docs/reference/libshumate-sections.txt
index 64e2c4e..549579b 100644
--- a/docs/reference/libshumate-sections.txt
+++ b/docs/reference/libshumate-sections.txt
@@ -49,10 +49,6 @@ shumate_marker_animate_in
shumate_marker_animate_in_with_delay
shumate_marker_animate_out
shumate_marker_animate_out_with_delay
-shumate_marker_get_selection_color
-shumate_marker_get_selection_text_color
-shumate_marker_set_selection_color
-shumate_marker_set_selection_text_color
<SUBSECTION Standard>
SHUMATE_MARKER
SHUMATE_IS_MARKER
diff --git a/shumate/shumate-marker.c b/shumate/shumate-marker.c
index 24b63bc..88eb3e4 100644
--- a/shumate/shumate-marker.c
+++ b/shumate/shumate-marker.c
@@ -50,9 +50,6 @@
#include <cairo.h>
#include <math.h>
-static GdkRGBA SELECTED_COLOR = { 0.0, 0.2, 0.8, 1.0 };
-static GdkRGBA SELECTED_TEXT_COLOR = { 1.0, 1.0, 1.0, 1.0 };
-
enum
{
PROP_SELECTABLE = 1,
@@ -89,69 +86,6 @@ G_DEFINE_TYPE_WITH_CODE (ShumateMarker, shumate_marker, GTK_TYPE_WIDGET,
G_ADD_PRIVATE (ShumateMarker)
G_IMPLEMENT_INTERFACE (SHUMATE_TYPE_LOCATION, location_interface_init));
-/**
- * shumate_marker_set_selection_color:
- * @color: a #ClutterColor
- *
- * Changes the selection color, this is to ensure a better integration with
- * the desktop.
- */
-void
-shumate_marker_set_selection_color (GdkRGBA *color)
-{
- SELECTED_COLOR.red = color->red;
- SELECTED_COLOR.green = color->green;
- SELECTED_COLOR.blue = color->blue;
- SELECTED_COLOR.alpha = color->alpha;
-}
-
-
-/**
- * shumate_marker_get_selection_color:
- *
- * Gets the selection color.
- *
- * Returns: the selection color. Should not be freed.
- */
-const GdkRGBA *
-shumate_marker_get_selection_color ()
-{
- return &SELECTED_COLOR;
-}
-
-
-/**
- * shumate_marker_set_selection_text_color:
- * @color: a #ClutterColor
- *
- * Changes the selection text color, this is to ensure a better integration with
- * the desktop.
- */
-void
-shumate_marker_set_selection_text_color (GdkRGBA *color)
-{
- SELECTED_TEXT_COLOR.red = color->red;
- SELECTED_TEXT_COLOR.green = color->green;
- SELECTED_TEXT_COLOR.blue = color->blue;
- SELECTED_TEXT_COLOR.alpha = color->alpha;
-}
-
-
-/**
- * shumate_marker_get_selection_text_color:
- *
- * Gets the selection text color.
- *
- * Returns: the selection text color. Should not be freed.
- */
-const GdkRGBA *
-shumate_marker_get_selection_text_color ()
-{
- return &SELECTED_TEXT_COLOR;
-}
-
-
-
static void
shumate_marker_set_location (ShumateLocation *location,
diff --git a/shumate/shumate-marker.h b/shumate/shumate-marker.h
index 7cd45f1..3f50b55 100644
--- a/shumate/shumate-marker.h
+++ b/shumate/shumate-marker.h
@@ -67,12 +67,6 @@ void shumate_marker_animate_out (ShumateMarker *marker);
void shumate_marker_animate_out_with_delay (ShumateMarker *marker,
guint delay);
-void shumate_marker_set_selection_color (GdkRGBA *color);
-const GdkRGBA *shumate_marker_get_selection_color (void);
-
-void shumate_marker_set_selection_text_color (GdkRGBA *color);
-const GdkRGBA *shumate_marker_get_selection_text_color (void);
-
GtkWidget *shumate_marker_get_child (ShumateMarker *marker);
void shumate_marker_set_child (ShumateMarker *marker,
GtkWidget *child);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]