作図ソフト dia の改良版
Revision | e14a136b4bb63c05812fefdf75e31a2297341c9c (tree) |
---|---|
Time | 2007-03-11 22:38:18 |
Author | Lars Clausen <lclausen@src....> |
Commiter | Lars Clausen |
Pre7: Crash bugs, image rendering, unit spinner fix.
svn path=/trunk/; revision=3632
@@ -1,10 +1,38 @@ | ||
1 | 1 | 2007-03-11 Lars Clausen <lars@raeder.dk> |
2 | 2 | |
3 | + * NEWS: | |
4 | + * RELEASE-PROCESS: | |
5 | + * config.h.win32: | |
6 | + * doc/en/dia.xml: | |
7 | + * doc/pl/dia.xml: | |
8 | + * doc/eu/dia.xml: | |
9 | + * configure.in: Pre7 | |
10 | + | |
11 | + * lib/prop_geomtypes.c (lengthprop_get_widget): Default to cm in | |
12 | + display to be similar to other reals. | |
13 | + | |
14 | + * lib/widgets.c (dia_unit_spinner_value_changed): Leave space | |
15 | + before unit. | |
16 | + | |
17 | + * Makefile.am (desktopdir): Put .desktop file in right dir. Fixes | |
18 | + bug #415767. | |
19 | + | |
20 | + * app/diagram.c (diagram_group_selected): Don't try to group no | |
21 | + objects. Fixes bug #410483, though the overall problem of | |
22 | + activateable insensitive menu items remains. | |
23 | + | |
24 | + * lib/dia_image.c (dia_image_draw): | |
25 | + * lib/dia_image.h: | |
26 | + * lib/diagdkrenderer.c (draw_image): Give a GC to the image | |
27 | + rendering function -- also change to using gdk_draw_pixbuf. Fixes | |
28 | + bug #401774. | |
29 | + | |
3 | 30 | * lib/focus.c (remove_focus_object): Make sure a removed object no |
4 | 31 | longer has the active focus. Fixes bug #414708. |
5 | 32 | |
6 | 33 | * app/textedit.c (textedit_end_edit): Don't assert active_focus |
7 | 34 | when it might not be true (during destruction). |
35 | + (textedit_remove_focus): Free the old focus when done. | |
8 | 36 | |
9 | 37 | 2007-03-07 Steffen Macke <sdteffen@gmail.com> |
10 | 38 |
@@ -26,7 +26,7 @@ CLEANFILES = core-translation-report dia.keys dia.desktop | ||
26 | 26 | |
27 | 27 | #--- Adapted from http://svn.xfce.org/svn/xfce/libexo/trunk/exo-helper/helpers/Makefile.am |
28 | 28 | |
29 | -desktopdir = $(datadir) | |
29 | +desktopdir = $(datadir)/applications | |
30 | 30 | desktop_in_files = dia.desktop.in |
31 | 31 | desktop_DATA = $(desktop_in_files:.desktop.in=.desktop) |
32 | 32 |
@@ -1,3 +1,8 @@ | ||
1 | +dia-0.96-pre7: 11-Mar-2007 | |
2 | + | |
3 | + * Seventh prerelease for 0.96. Fixes two crash bugs and image redrawing | |
4 | + issues, as well as a few minor issues. | |
5 | + | |
1 | 6 | dia-0.96-pre6: 5-Mar-2007 |
2 | 7 | |
3 | 8 | * Sixth prerelease for 0.96. I18n fixes, debugging output removed, some |
@@ -1100,6 +1100,11 @@ void diagram_group_selected(Diagram *dia) | ||
1100 | 1100 | GList *orig_list; |
1101 | 1101 | Change *change; |
1102 | 1102 | |
1103 | + if (g_list_length(dia->data->selected) < 1) { | |
1104 | + message_error("Trying to group with no selected objects."); | |
1105 | + return; | |
1106 | + } | |
1107 | + | |
1103 | 1108 | #if 0 |
1104 | 1109 | /* the following is wrong as it screws up the selected list, see bug #153525 |
1105 | 1110 | * I just don't get what was originally intented so please speak up if you know --hb |
@@ -1132,13 +1137,13 @@ void diagram_group_selected(Diagram *dia) | ||
1132 | 1137 | group = group_create(group_list); |
1133 | 1138 | change = undo_group_objects(dia, group_list, group, orig_list); |
1134 | 1139 | (change->apply)(change, dia); |
1135 | - | |
1140 | + | |
1136 | 1141 | /* Select the created group */ |
1137 | 1142 | diagram_select(dia, group); |
1138 | 1143 | |
1139 | 1144 | diagram_modified(dia); |
1140 | 1145 | diagram_flush(dia); |
1141 | - | |
1146 | + | |
1142 | 1147 | undo_set_transactionpoint(dia->undo); |
1143 | 1148 | } |
1144 | 1149 |
@@ -170,6 +170,7 @@ textedit_remove_focus(DiaObject *obj, Diagram *diagram) | ||
170 | 170 | /* TODO: make sure the focus is deactivated */ |
171 | 171 | textedit_end_edit(ddisplay_active(), old_focus); |
172 | 172 | } |
173 | + g_free(old_focus); | |
173 | 174 | } |
174 | 175 | |
175 | 176 | /** Call when the entire list of focusable texts gets reset. */ |
@@ -18,7 +18,7 @@ | ||
18 | 18 | #undef LOCALEDIR /* needs to be calculated at runtime */ |
19 | 19 | /* NOT: #define LOCALEDIR "../lib/locale" */ |
20 | 20 | |
21 | -#define VERSION "0.96-pre6" | |
21 | +#define VERSION "0.96-pre7" | |
22 | 22 | |
23 | 23 | /* |
24 | 24 | * We are linking libxml as DLL with either msvc or mingw, but this |
@@ -1,6 +1,6 @@ | ||
1 | 1 | dnl Process this -*- autoconf -*- file with autoconf to produce a |
2 | 2 | dnl configure script. |
3 | -AC_INIT(dia, 0.96-pre6, http://bugzilla.gnome.org/enter_bug.cgi?product=dia) | |
3 | +AC_INIT(dia, 0.96-pre7, http://bugzilla.gnome.org/enter_bug.cgi?product=dia) | |
4 | 4 | AC_CONFIG_SRCDIR(app/diagram.c) |
5 | 5 | AM_INIT_AUTOMAKE(AC_PACKAGE_NAME,AC_PACKAGE_VERSION) |
6 | 6 |
@@ -8,7 +8,7 @@ | ||
8 | 8 | |
9 | 9 | [ |
10 | 10 | |
11 | - <!ENTITY VERSION "0.96-pre6"> | |
11 | + <!ENTITY VERSION "0.96-pre7"> | |
12 | 12 | |
13 | 13 | <!ENTITY INTRODUCTION SYSTEM "intro.xml"> |
14 | 14 |
@@ -4,7 +4,7 @@ | ||
4 | 4 | |
5 | 5 | <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "../../dtd/docbookx.dtd" [ |
6 | 6 | |
7 | - <!ENTITY VERSION "0.96-pre6"> | |
7 | + <!ENTITY VERSION "0.96-pre7"> | |
8 | 8 | |
9 | 9 | <!ENTITY INTRODUCTION SYSTEM "intro.xml"> |
10 | 10 |
@@ -1,7 +1,7 @@ | ||
1 | 1 | <?xml version="1.0" encoding="iso-8859-1"?> |
2 | 2 | |
3 | 3 | <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "../../dtd/docbookx.dtd"[ |
4 | -<!ENTITY VERSION "0.96-pre6"> | |
4 | +<!ENTITY VERSION "0.96-pre7"> | |
5 | 5 | <!ENTITY INTRODUCTION SYSTEM "intro.xml"> |
6 | 6 | <!ENTITY QUICKSTART SYSTEM "usage-quickstart.xml"> |
7 | 7 | <!ENTITY CANVAS SYSTEM "usage-canvas.xml"> |
@@ -134,7 +134,7 @@ dia_image_release(DiaImage image) | ||
134 | 134 | * @param height Height in pixels of rendering in window. |
135 | 135 | */ |
136 | 136 | void |
137 | -dia_image_draw(DiaImage image, GdkWindow *window, | |
137 | +dia_image_draw(DiaImage image, GdkWindow *window, GdkGC *gc, | |
138 | 138 | int x, int y, int width, int height) |
139 | 139 | { |
140 | 140 | GdkPixbuf *scaled; |
@@ -164,10 +164,10 @@ dia_image_draw(DiaImage image, GdkWindow *window, | ||
164 | 164 | } |
165 | 165 | |
166 | 166 | /* Once we can render Alpha, we'll do it! */ |
167 | - gdk_pixbuf_render_to_drawable_alpha(scaled, window, | |
168 | - 0, 0, x, y, width, height, | |
169 | - GDK_PIXBUF_ALPHA_BILEVEL, 128, | |
170 | - GDK_RGB_DITHER_NORMAL, 0, 0); | |
167 | + gdk_draw_pixbuf(window, gc, scaled, | |
168 | + 0, 0, x, y, width, height, | |
169 | + GDK_RGB_DITHER_NORMAL, 0, 0); | |
170 | + | |
171 | 171 | #ifndef SCALING_CACHE |
172 | 172 | gdk_pixbuf_unref(scaled); |
173 | 173 | #endif |
@@ -30,7 +30,7 @@ DiaImage dia_image_get_broken(void); | ||
30 | 30 | DiaImage dia_image_load(gchar *filename); |
31 | 31 | void dia_image_add_ref(DiaImage image); |
32 | 32 | void dia_image_release(DiaImage image); |
33 | -void dia_image_draw(DiaImage image, GdkWindow *window, | |
33 | +void dia_image_draw(DiaImage image, GdkWindow *window, GdkGC *gc, | |
34 | 34 | int x, int y, int width, int height); |
35 | 35 | |
36 | 36 | int dia_image_width(DiaImage image); |
@@ -813,7 +813,7 @@ draw_image (DiaRenderer *object, | ||
813 | 813 | dia_transform_coords(renderer->transform, point->x, point->y, |
814 | 814 | &real_x, &real_y); |
815 | 815 | |
816 | - dia_image_draw(image, renderer->pixmap, real_x, real_y, | |
816 | + dia_image_draw(image, renderer->pixmap, renderer->gc, real_x, real_y, | |
817 | 817 | real_width, real_height); |
818 | 818 | } |
819 | 819 | } |
@@ -181,7 +181,7 @@ lengthprop_get_widget(LengthProperty *prop, PropDialog *dialog) | ||
181 | 181 | G_MINFLOAT, |
182 | 182 | G_MAXFLOAT, |
183 | 183 | 0.1, 1.0, 1.0)); |
184 | - GtkWidget *ret = dia_unit_spinner_new(adj, 2, DIA_UNIT_MILLIMETER); | |
184 | + GtkWidget *ret = dia_unit_spinner_new(adj, 2, DIA_UNIT_CENTIMETER); | |
185 | 185 | /* gtk_spin_button_set_numeric(GTK_SPIN_BUTTON(ret),TRUE);*/ |
186 | 186 | prophandler_connect(&prop->common,GTK_OBJECT(adj),"value_changed"); |
187 | 187 |
@@ -1470,7 +1470,7 @@ dia_unit_spinner_value_changed(GtkAdjustment *adjustment, | ||
1470 | 1470 | char buf[256]; |
1471 | 1471 | GtkSpinButton *sbutton = GTK_SPIN_BUTTON(spinner); |
1472 | 1472 | |
1473 | - g_snprintf(buf, sizeof(buf), "%0.*f%s", sbutton->digits, adjustment->value, | |
1473 | + g_snprintf(buf, sizeof(buf), "%0.*f %s", sbutton->digits, adjustment->value, | |
1474 | 1474 | units[spinner->unit_num].unit); |
1475 | 1475 | gtk_entry_set_text(GTK_ENTRY(spinner), buf); |
1476 | 1476 | } |