Mailinglist Archive: yast-commit (126 mails)

< Previous Next >
[yast-commit] r67651 - in /branches/SuSE-Code-11-SP2-Branch/gtk: VERSION package/yast2-gtk.changes src/ygtkrichtext.c
Author: tgoettlicher
Date: Fri Mar 16 16:05:38 2012
New Revision: 67651

URL: http://svn.opensuse.org/viewcvs/yast?rev=67651&view=rev
Log:
- Fix for bnc #751309: markup of release notes


Modified:
branches/SuSE-Code-11-SP2-Branch/gtk/VERSION
branches/SuSE-Code-11-SP2-Branch/gtk/package/yast2-gtk.changes
branches/SuSE-Code-11-SP2-Branch/gtk/src/ygtkrichtext.c

Modified: branches/SuSE-Code-11-SP2-Branch/gtk/VERSION
URL:
http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/gtk/VERSION?rev=67651&r1=67650&r2=67651&view=diff
==============================================================================
--- branches/SuSE-Code-11-SP2-Branch/gtk/VERSION (original)
+++ branches/SuSE-Code-11-SP2-Branch/gtk/VERSION Fri Mar 16 16:05:38 2012
@@ -1 +1 @@
-2.21.98
+2.21.99

Modified: branches/SuSE-Code-11-SP2-Branch/gtk/package/yast2-gtk.changes
URL:
http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/gtk/package/yast2-gtk.changes?rev=67651&r1=67650&r2=67651&view=diff
==============================================================================
--- branches/SuSE-Code-11-SP2-Branch/gtk/package/yast2-gtk.changes (original)
+++ branches/SuSE-Code-11-SP2-Branch/gtk/package/yast2-gtk.changes Fri Mar 16
16:05:38 2012
@@ -1,4 +1,10 @@
-------------------------------------------------------------------
+Fri Mar 16 16:04:55 CET 2012 - tgoettlicher@xxxxxxx
+
+- Fix for bnc #751309: markup of release notes
+- 2.21.99
+
+-------------------------------------------------------------------
Wed Oct 5 12:48:52 UTC 2011 - lslezak@xxxxxxx

- removed non-functional "Close software manager when done" check

Modified: branches/SuSE-Code-11-SP2-Branch/gtk/src/ygtkrichtext.c
URL:
http://svn.opensuse.org/viewcvs/yast/branches/SuSE-Code-11-SP2-Branch/gtk/src/ygtkrichtext.c?rev=67651&r1=67650&r2=67651&view=diff
==============================================================================
--- branches/SuSE-Code-11-SP2-Branch/gtk/src/ygtkrichtext.c (original)
+++ branches/SuSE-Code-11-SP2-Branch/gtk/src/ygtkrichtext.c Fri Mar 16 16:05:38
2012
@@ -68,8 +68,16 @@
return FALSE;

const char *link = get_link (GTK_TEXT_VIEW (text_view), event->x,
event->y);
- if (link) // report link
- g_signal_emit (YGTK_RICH_TEXT (text_view), link_clicked_signal,
0, link);
+ if (link) {
+ if (*link == '#') {
+ GtkTextMark *mark = gtk_text_buffer_get_mark (buffer,
link + 1);
+ if (mark)
+ gtk_text_view_scroll_to_mark (GTK_TEXT_VIEW
(text_view), mark, 0.4, TRUE, 0, 0);
+ } else {
+ // report link
+ g_signal_emit (YGTK_RICH_TEXT (text_view),
link_clicked_signal, 0, link);
+ }
+ }
return FALSE;
}

@@ -80,7 +88,7 @@
static gboolean isBlockTag (const char *tag)
{
static const char *Tags[] =
- { "blockquote", "h1", "h2", "h3", "h4", "h5", "li", "p", "pre" };
+ { "blockquote", "dd", "dl", "dt", "h1", "h2", "h3", "h4", "h5", "li",
"p", "pre" };
void *ret;
ret = bsearch (&tag, Tags, sizeof (Tags)/sizeof(char*), sizeof(char *),
(void*)mystrcmp);
return ret != 0;
@@ -88,7 +96,7 @@
static gboolean isIdentTag (const char *tag)
{
static const char *Tags[] =
- { "blockquote", "ol", "ul" };
+ { "blockquote", "dd", "ol", "ul" };
void *ret;
ret = bsearch (&tag, Tags, sizeof (Tags)/sizeof(char*), sizeof(char *),
(void*)mystrcmp);
return ret != 0;
@@ -355,6 +363,10 @@
g_object_set (tag->tag,
"foreground-gdk", &link_color, NULL);
g_object_set_data (G_OBJECT (tag->tag), "link",
g_strdup (attribute_values[0]));
}
+ else if (attribute_names[0] &&
+ !g_ascii_strcasecmp (attribute_names[0],
"name")) {
+ gtk_text_buffer_create_mark (state->buffer,
attribute_values[0], &iter, TRUE);
+ }
else
g_warning ("Unknown a attribute: '%s'",
attribute_names[0]);
}

--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages