diff -Nru nted-1.10.18/debian/changelog nted-1.10.18/debian/changelog --- nted-1.10.18/debian/changelog 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/changelog 2011-05-30 20:43:10.000000000 +0000 @@ -1,3 +1,15 @@ +nted (1.10.18-2) unstable; urgency=low + + * Use source format 3.0 (quilt) + * Major cleanup of debian/rules + * Drop patch linking.generated in favor of using autoreconf during the + configure step + * Improve patch 'linking' to fix a FTBFS with gcc-4.6 (closes: #628259) + * Fix new compilation warnings for gcc-4.6 + * Bump Standards-Version to 3.9.2 (no changes needed) + + -- Gilles Filippini Mon, 30 May 2011 22:42:41 +0200 + nted (1.10.18-1) unstable; urgency=low * New upstream version: diff -Nru nted-1.10.18/debian/control nted-1.10.18/debian/control --- nted-1.10.18/debian/control 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/control 2011-05-30 20:42:36.000000000 +0000 @@ -3,8 +3,8 @@ Priority: optional Maintainer: Gilles Filippini Homepage: http://vsr.informatik.tu-chemnitz.de/staff/jan/nted/nted.xhtml -Build-Depends: debhelper (>= 7.0.50~), autotools-dev, libasound2-dev, libcairo2-dev, libgtk2.0-dev, quilt (>= 0.46-7~), xmlto, poxml -Standards-Version: 3.9.1 +Build-Depends: debhelper (>= 7.0.50~), autotools-dev, libasound2-dev, libcairo2-dev, libgtk2.0-dev, xmlto, poxml, automake +Standards-Version: 3.9.2 Package: nted Architecture: any diff -Nru nted-1.10.18/debian/nted-doc.install nted-1.10.18/debian/nted-doc.install --- nted-1.10.18/debian/nted-doc.install 1970-01-01 00:00:00.000000000 +0000 +++ nted-1.10.18/debian/nted-doc.install 2011-05-17 22:27:49.000000000 +0000 @@ -0,0 +1,2 @@ +# Trailing '/' to install subdirs only +debian/tmp/usr/share/doc/nted/*/ diff -Nru nted-1.10.18/debian/nted.install nted-1.10.18/debian/nted.install --- nted-1.10.18/debian/nted.install 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/nted.install 2011-05-17 20:37:14.000000000 +0000 @@ -1,4 +1,4 @@ -debian/tmp/usr/share/nted +debian/tmp/usr/share/nted/ntedfont.pfa debian/tmp/usr/share/locale debian/tmp/usr/share/applications debian/tmp/usr/share/pixmaps diff -Nru nted-1.10.18/debian/patches/empty_page_reposit.patch nted-1.10.18/debian/patches/empty_page_reposit.patch --- nted-1.10.18/debian/patches/empty_page_reposit.patch 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/patches/empty_page_reposit.patch 2011-05-19 21:45:32.000000000 +0000 @@ -1,9 +1,9 @@ Remove empty pages resulting from staff repositionning. -diff --git a/mainwindow.cpp b/mainwindow.cpp -index 7263565..1686c49 100644 ---- a/mainwindow.cpp -+++ b/mainwindow.cpp -@@ -1250,14 +1250,14 @@ void NedMainWindow::reposit(NedCommandList *command_list /* = NULL */, NedPage * +Index: nted/mainwindow.cpp +=================================================================== +--- nted.orig/mainwindow.cpp 2011-05-19 23:45:01.000000000 +0200 ++++ nted/mainwindow.cpp 2011-05-19 23:45:01.000000000 +0200 +@@ -1247,14 +1247,14 @@ GList *lptr, *plptr; GtkWidget *progressbar = NULL, *progressdialog = NULL; bool changes, ch; @@ -20,7 +20,7 @@ int measure_number; -@@ -1362,7 +1362,7 @@ void NedMainWindow::reposit(NedCommandList *command_list /* = NULL */, NedPage * +@@ -1359,7 +1359,7 @@ } while (changes); } @@ -29,7 +29,7 @@ if (command_list != NULL) { command_list->setRenumber(); for (lptr = g_list_first(m_pages); lptr; lptr = g_list_next(lptr)) { -@@ -1380,7 +1380,7 @@ void NedMainWindow::reposit(NedCommandList *command_list /* = NULL */, NedPage * +@@ -1377,7 +1377,7 @@ } } diff -Nru nted-1.10.18/debian/patches/linking nted-1.10.18/debian/patches/linking --- nted-1.10.18/debian/patches/linking 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/patches/linking 2011-05-17 05:53:43.000000000 +0000 @@ -7,7 +7,7 @@ freechord.h freespacer.h pangocairotext.h freechordname.h midiimporter.h midirecorder.h nted_LDADD = commands/libcommands.a dialogs/libdialogs.a chords/libchords.a idiotseditor/libidiotseditor.a $(CAIRO_LIBS) $(PANGO_LIBS) $(GTK_LIBS) $(X11_LIBS) -lasound -+nted_LDFLAGS = --as-needed ++nted_LDFLAGS = -Wl,--as-needed cleanup: maintainer-clean cleanup-local diff -Nru nted-1.10.18/debian/patches/linking.generated nted-1.10.18/debian/patches/linking.generated --- nted-1.10.18/debian/patches/linking.generated 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/patches/linking.generated 1970-01-01 00:00:00.000000000 +0000 @@ -1,68 +0,0 @@ -Companion patch of linking to transform makefile.in accordingly. -Index: nted/Makefile.in -=================================================================== ---- nted.orig/Makefile.in 2011-03-15 23:12:38.000000000 +0100 -+++ nted/Makefile.in 2011-03-15 23:13:47.000000000 +0100 -@@ -64,12 +64,7 @@ - AUTHORS COPYING ChangeLog INSTALL NEWS config.guess \ - config.rpath config.sub depcomp install-sh missing - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 --am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \ -- $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/intlmacosx.m4 \ -- $(top_srcdir)/m4/lib-ld.m4 $(top_srcdir)/m4/lib-link.m4 \ -- $(top_srcdir)/m4/lib-prefix.m4 $(top_srcdir)/m4/nls.m4 \ -- $(top_srcdir)/m4/po.m4 $(top_srcdir)/m4/progtest.m4 \ -- $(top_srcdir)/configure.in -+am__aclocal_m4_deps = $(top_srcdir)/configure.in - am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) - am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ -@@ -100,6 +95,8 @@ - chords/libchords.a idiotseditor/libidiotseditor.a \ - $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ - $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) -+nted_LINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(nted_LDFLAGS) \ -+ $(LDFLAGS) -o $@ - DEFAULT_INCLUDES = -I.@am__isrc@ - depcomp = $(SHELL) $(top_srcdir)/depcomp - am__depfiles_maybe = depfiles -@@ -201,6 +198,7 @@ - CC = @CC@ - CCDEPMODE = @CCDEPMODE@ - CFLAGS = @CFLAGS@ -+CPP = @CPP@ - CPPFLAGS = @CPPFLAGS@ - CXX = @CXX@ - CXXDEPMODE = @CXXDEPMODE@ -@@ -211,12 +209,14 @@ - ECHO_C = @ECHO_C@ - ECHO_N = @ECHO_N@ - ECHO_T = @ECHO_T@ -+EGREP = @EGREP@ - EXEEXT = @EXEEXT@ - FT2_CFLAGS = @FT2_CFLAGS@ - FT2_LIBS = @FT2_LIBS@ - GETTEXT_MACRO_VERSION = @GETTEXT_MACRO_VERSION@ - GMSGFMT = @GMSGFMT@ - GMSGFMT_015 = @GMSGFMT_015@ -+GREP = @GREP@ - GTK_CFLAGS = @GTK_CFLAGS@ - GTK_LIBS = @GTK_LIBS@ - IMAGE2HEADER = @IMAGE2HEADER@ -@@ -348,6 +348,7 @@ - freespacer.h pangocairotext.h freechordname.h midiimporter.h \ - midirecorder.h - nted_LDADD = commands/libcommands.a dialogs/libdialogs.a chords/libchords.a idiotseditor/libidiotseditor.a $(CAIRO_LIBS) $(PANGO_LIBS) $(GTK_LIBS) $(X11_LIBS) -lasound -+nted_LDFLAGS = --as-needed - ACLOCAL_AMFLAGS = -I m4 - EXTRA_DIST = config.rpath INSTALL README - all: config.h -@@ -445,7 +446,7 @@ - -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) - nted$(EXEEXT): $(nted_OBJECTS) $(nted_DEPENDENCIES) - @rm -f nted$(EXEEXT) -- $(CXXLINK) $(nted_OBJECTS) $(nted_LDADD) $(LIBS) -+ $(nted_LINK) $(nted_OBJECTS) $(nted_LDADD) $(LIBS) - - mostlyclean-compile: - -rm -f *.$(OBJEXT) diff -Nru nted-1.10.18/debian/patches/series nted-1.10.18/debian/patches/series --- nted-1.10.18/debian/patches/series 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/patches/series 2011-05-19 21:46:17.000000000 +0000 @@ -1,8 +1,6 @@ remove-encoding-key-in-desktop-file linking -linking.generated doc-requirements warnings -#fix-midi-import empty_page_reposit.patch fix-empty-captions.patch diff -Nru nted-1.10.18/debian/patches/warnings nted-1.10.18/debian/patches/warnings --- nted-1.10.18/debian/patches/warnings 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/patches/warnings 2011-05-19 21:44:47.000000000 +0000 @@ -25,3 +25,644 @@ strcpy(str1, m_text); strcat(str1, text); setText(str1, zoom, m_hide_hyphen); +Index: nted/idiotseditor/idiotseditor.cpp +=================================================================== +--- nted.orig/idiotseditor/idiotseditor.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/idiotseditor/idiotseditor.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -271,7 +271,7 @@ + void NedIdiotsInstrument::draw(Display *dpy, Drawable d, GC xgc, GC x_border_gc, double zoom_value, double xleft, double ytop, double visible_start_pos, double visible_end_pos) { + GList *lptr; + NedIdNote *note; +- int voice; ++ //int voice; + + XSetLineAttributes(dpy, x_border_gc, NOTE_BORDER_LINE_THICK, LineSolid, CapRound, JoinMiter); + XSetForeground(dpy, x_border_gc, 0x000000); +@@ -640,7 +640,6 @@ + NedIdNote * note; + unsigned long long duration, start_time, end_time, split_time; + int dist; +- int pitch; + int pos; + int voi; + int key; +@@ -689,7 +688,6 @@ + break; + } + end_time = note->m_midi_stop; +- pitch = note->m_pitch; + note->m_midi_stop = split_time; + if (note->m_max_stop > 0 && note->m_max_stop <= note->m_midi_start) { + NedResource::Abort("NedIdiotsInstrument::splitNotesAtMeasureStart(3)"); +@@ -1577,7 +1575,6 @@ + if (note->m_midi_stop / FACTOR * zoom_value < visible_start_pos) continue; + double startpos = X_POS(note->m_midi_start); + double endpos = X_POS(note->m_midi_stop); +- double ypos = PITCH_TO_YPOS(note->m_pitch); + if (note->isInRect(event->x, event->y, zoom_value, xleft, ytop)) { + m_selected_note = note; + dist = event->x - startpos; +@@ -1618,7 +1615,7 @@ + m_current_instrument_number(0), m_channel_nr(0), m_last_inserted(NULL), + m_sort_according_instrument(sort_instruments), m_dont_split(dont_split), + m_X11version(X11Version), m_min_denom(1), m_instruments(NULL), m_specials(NULL), +- m_mouse_x(0.0), m_mouse_y(0.0), m_dpy(NULL), m_off_x(0.0), m_off_y(0.0) { ++ m_mouse_x(0.0), m_mouse_y(0.0), m_off_x(0.0), m_off_y(0.0), m_dpy(NULL) { + + m_pending_inst_name[0] = '\0'; + GtkWidget *menubar; +@@ -1837,7 +1834,6 @@ + double xleft = gtk_adjustment_get_value(id_editor->m_hadjust); + double ytop = gtk_adjustment_get_value(id_editor->m_vadjust); + int width = id_editor->m_drawing_area->allocation.width; +- int height = id_editor->m_drawing_area->allocation.height; + + visible_start_pos = xleft; + visible_end_pos = xleft + width; +@@ -1858,7 +1854,6 @@ + if ((event->state & GDK_BUTTON1_MASK) == 0) return FALSE; + NedIdiotsEditor *id_editor = (NedIdiotsEditor*) data; + if (id_editor->motion_mode == MOTION_MODE_NONE) return FALSE; +- NedIdiotsInstrument *inst = (NedIdiotsInstrument *) g_list_first(id_editor->m_instruments)->data; + id_editor->m_off_x = event->x - id_editor->m_mouse_x; + id_editor->m_off_y = event->y - id_editor->m_mouse_y; + id_editor->repaint(); +@@ -1878,13 +1873,14 @@ + id_editor->motion_mode = MOTION_MODE_NONE; + id_editor->m_off_x = id_editor->m_off_y = 0.0; + id_editor->repaint(); ++ return FALSE; + } + + void NedIdiotsInstrument::recomputeNotes(double zoom_value, double xleft, double ytop) { + if (!m_selected_note) return; + GList *lptr; + NedIdNote *note; +- unsigned int f, snap, xpitch; ++ unsigned int f, snap; + double xstart, xend, ypos; + unsigned int newstart, newstop; + int newpitch; +Index: nted/dialogs/staffcontextdialog.cpp +=================================================================== +--- nted.orig/dialogs/staffcontextdialog.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/dialogs/staffcontextdialog.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -820,7 +820,6 @@ + gboolean NedStaffContextDialog::draw_clefs(GtkWidget *widget, GdkEventExpose *event, gpointer data) { + #define ZOOM_LEVEL 9 + NedStaffContextDialog *the_dialog = (NedStaffContextDialog *) data; +- cairo_scaled_font_t *scaled_font; + cairo_glyph_t glyph; + int i; + double y_offs = 0.0, oct_y_offs = 0.0, oct_x_offs = 0.0; +@@ -834,8 +833,9 @@ + cairo_fill(cr); + + cairo_set_source_rgb (cr, 0.0, 0.0, 0.0); +- scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + #ifdef HAS_SET_SCALED_FONT ++ cairo_scaled_font_t *scaled_font; ++ scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + cairo_set_scaled_font (cr, scaled_font); + #else + cairo_set_font_face(cr, NedResource::getFontFace()); +@@ -1026,7 +1026,6 @@ + + void NedStaffContextDialog::OnVoiceToggle(GtkToggleButton *togglebutton, gpointer data) { + NedStaffContextDialog *context_dialog = (NedStaffContextDialog *) data; +- int oldvoice = context_dialog->m_current_voice; + + if (togglebutton == GTK_TOGGLE_BUTTON(context_dialog->m_radio_all)) { + if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(context_dialog->m_radio_all))) { +@@ -1094,7 +1093,6 @@ + } + + void NedStaffContextDialog::OnSingleMutedToggle(GtkToggleButton *togglebutton, gpointer data) { +- int i; + bool toggle_state; + bool all_muted = true; + bool none_muted = true; +Index: nted/dialogs/clefconfigdialog.cpp +=================================================================== +--- nted.orig/dialogs/clefconfigdialog.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/dialogs/clefconfigdialog.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -130,7 +130,6 @@ + gboolean NedClefConfigDialog::draw_clefs(GtkWidget *widget, GdkEventExpose *event, gpointer data) { + #define ZOOM_LEVEL 9 + NedClefConfigDialog *the_dialog = (NedClefConfigDialog *) data; +- cairo_scaled_font_t *scaled_font; + cairo_glyph_t glyph; + int i; + double y_offs = 0.0, oct_y_offs = 0.0, oct_x_offs = 0.0; +@@ -144,8 +143,9 @@ + cairo_fill(cr); + + cairo_set_source_rgb (cr, 0.0, 0.0, 0.0); +- scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + #ifdef HAS_SET_SCALED_FONT ++ cairo_scaled_font_t *scaled_font; ++ scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + cairo_set_scaled_font (cr, scaled_font); + #else + cairo_set_font_face(cr, NedResource::getFontFace()); +Index: nted/dialogs/druminfo.cpp +=================================================================== +--- nted.orig/dialogs/druminfo.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/dialogs/druminfo.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -76,7 +76,7 @@ + {"ridecymbala", "cymra",51, CROSS_NOTE3, NULL, 9 }, + {"hibongo", "boh", 60, NORMAL_NOTE, NULL, 3 }, + {"ridebell", "rb", 53, NORMAL_NOTE, NULL, 9 }, +- {NULL, NULL, 0, NULL, NULL} ++ {NULL, NULL, 0, 0, NULL, 0} + }; + + struct d_info_str current_dinfo[G_N_ELEMENTS(default_dinfo)]; +Index: nted/dialogs/tools.cpp +=================================================================== +--- nted.orig/dialogs/tools.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/dialogs/tools.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -319,13 +319,11 @@ + bool X11buttonGroup::allowStateChange(X11button *button) { + GList *lptr; + int c = 0; +- bool isAmongActives = false; + if (m_all_inactive_allowed) return true; + + for (lptr = g_list_first(m_buttons); lptr; lptr = g_list_next(lptr)) { + if (!((X11button *) lptr->data)->m_active) continue; + c++; +- if ((X11button *) lptr->data == button) isAmongActives = true; + } + + if (c > 1) return true; +@@ -360,13 +358,11 @@ + #define CREATE_MINI_X11_EMPTY(back, up) createX11PixmapFromGdkPixbuffer(dpy, screen, d, ggc, NULL, back, up); + + NedTools::NedTools() : +- m_back_pix(NULL), m_current_row(-1), m_current_column(-1), m_current_panel(0), m_buttons_created(false), m_dpy(NULL) ++ m_dpy(NULL), m_back_pix(NULL), m_current_row(-1), m_current_column(-1), m_current_panel(0), m_buttons_created(false) + { + GdkColor bgcolor; + int wx, wy; + NedMainWindow *last_main; +- GdkDisplay *display = NULL; +- GdkScreen *screen = NULL; + + m_toolbox = gtk_window_new (GTK_WINDOW_TOPLEVEL); + gtk_window_set_title (GTK_WINDOW (m_toolbox), _("Toolbox")); +@@ -383,8 +379,6 @@ + m_mini_spaces = (4 * m_back_img_width - 4 * m_back_miniimg_width) / 5; + + if ((last_main = NedResource::getMainwWindowWithLastFocus()) != NULL) { +- display = gdk_display_get_default (); +- screen = gdk_display_get_default_screen (display); + gdk_window_get_root_origin(GDK_WINDOW(last_main->getWindow()->window), &wx, &wy); + gtk_window_move(GTK_WINDOW (m_toolbox), wx + NedResource::m_toolboxX, wy + NedResource::m_toolboxY); + } +@@ -454,13 +448,9 @@ + + void NedTools::setToolboxTransient(NedMainWindow *m_win) { + int wx, wy; +- GdkDisplay *display = NULL; +- GdkScreen *screen = NULL; + + gtk_window_set_transient_for(GTK_WINDOW (m_toolbox), (GTK_WINDOW (m_win->getWindow()))); + +- display = gdk_display_get_default (); +- screen = gdk_display_get_default_screen (display); + gdk_window_get_root_origin(GDK_WINDOW(m_win->getWindow()->window), &wx, &wy); + gtk_window_move(GTK_WINDOW (m_toolbox), wx + NedResource::m_toolboxX, wy + NedResource::m_toolboxY); + +Index: nted/dialogs/drumconfigdialog.cpp +=================================================================== +--- nted.orig/dialogs/drumconfigdialog.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/dialogs/drumconfigdialog.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -748,7 +748,6 @@ + gboolean NedDrumConfigDialog::OnExpose(GtkWidget *widget, GdkEventExpose *event, gpointer data) { + #define ZOOM_LEVEL 9 + NedDrumConfigDialog *drum_config_dialog = (NedDrumConfigDialog *) data; +- cairo_scaled_font_t *scaled_font; + cairo_glyph_t glyph; + int i; + +@@ -760,8 +759,9 @@ + cairo_fill(cr); + + cairo_set_source_rgb (cr, 0.0, 0.0, 0.0); +- scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + #ifdef HAS_SET_SCALED_FONT ++ cairo_scaled_font_t *scaled_font; ++ scaled_font = NedResource::getScaledFont(ZOOM_LEVEL); + cairo_set_scaled_font (cr, scaled_font); + #else + cairo_set_font_face(cr, NedResource::getFontFace()); +Index: nted/chords/chorddialog.cpp +=================================================================== +--- nted.orig/chords/chorddialog.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/chords/chorddialog.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -58,7 +58,6 @@ + GtkObject *root_list_adjustment; + GtkWidget *root_list_scroll; + GtkListStore * modies_list_store; +- GtkCellRenderer *modies_list_renderer; + GtkTreeViewColumn *modies_list_column; + GtkObject *modies_list_adjustment; + GtkWidget *modies_list_scroll; +@@ -146,7 +145,6 @@ + gtk_list_store_set (modies_list_store, &iter, 0, *cptr, -1); + } + m_modies_list_view = gtk_tree_view_new_with_model(GTK_TREE_MODEL(modies_list_store)); +- modies_list_renderer = gtk_cell_renderer_text_new (); + modies_list_column = gtk_tree_view_column_new_with_attributes (_("mody"), root_list_renderer, "text", 0, NULL); + gtk_tree_view_append_column (GTK_TREE_VIEW (m_modies_list_view), modies_list_column); + modies_list_adjustment = gtk_adjustment_new (0.0, 0.0, ll, 1.0, 10.0, 10.0); +Index: nted/mainwindow.cpp +=================================================================== +--- nted.orig/mainwindow.cpp 2011-05-19 22:47:48.000000000 +0200 ++++ nted/mainwindow.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -1165,12 +1165,11 @@ + + void NedMainWindow::draw (cairo_t *cr, int width, int height) + { +- cairo_scaled_font_t *scaled_font; + bool dummy = false; +- scaled_font = NedResource::getScaledFont(m_current_zoom_level); +- GdkColor sel_color; + //cairo_scale(cr, 0.4, 0.4); + #ifdef HAS_SET_SCALED_FONT ++ cairo_scaled_font_t *scaled_font; ++ scaled_font = NedResource::getScaledFont(m_current_zoom_level); + cairo_set_scaled_font (cr, scaled_font); + #else + cairo_set_font_face(cr, NedResource::getFontFace()); +@@ -1208,8 +1207,6 @@ + cairo_stroke(cr); + + cairo_scale(cr, getCurrentScale(), getCurrentScale()); +- sel_color.pixel = 0; +- sel_color.red = 200; sel_color.green = 0; sel_color.blue = 250; + for (lptr = g_list_first(m_selected_group); lptr; lptr = g_list_next(lptr)) { + ((NedChordOrRest *) lptr->data)->draw(cr, &dummy); + } +@@ -1224,9 +1221,9 @@ + bool dummy; + cairo_t *cr; + cr = gdk_cairo_create (m_drawing_area->window); ++#ifdef HAS_SET_SCALED_FONT + cairo_scaled_font_t *scaled_font; + scaled_font = NedResource::getScaledFont(m_current_zoom_level); +-#ifdef HAS_SET_SCALED_FONT + cairo_set_scaled_font (cr, scaled_font); + #else + cairo_set_font_face(cr, NedResource::getFontFace()); +@@ -3725,7 +3722,7 @@ + GList *lptr; + int i, j, k; + unsigned int m, voice_mask[m_staff_count]; +- int the_voice = 0, voice_count[m_staff_count]; ++ int voice_count[m_staff_count]; + int last_line; + unsigned int midi_len; + NedSystem *last_system = NULL, *dummy = NULL; +@@ -3834,12 +3831,10 @@ + } + clef_number = m_staff_contexts[i].m_clef_number; + voice_count[i] = 0; +- the_voice = 0; + for (j = 0; j < VOICE_COUNT; j++) { + m = (1 << j); + if ((m & voice_mask[i]) != 0) { + voice_count[i]++; +- the_voice = j; + } + } + +@@ -6493,7 +6488,6 @@ + + bool NedMainWindow::do_import_from_other(NedImporter *im) { + int i, j; +- bool first = true; + bool first_measure = true; + bool overflow; + NedPage *current_page; +@@ -6603,7 +6597,6 @@ + current_page->insertSystem(current_system); + } + current_system = current_page->appendSystem(); +- first = false; + } + while (!im->is_eof()) { + current_system->empty(); +@@ -7135,7 +7128,6 @@ + bool state, portrait; + const char *paper; + int w, h; +- bool p; + if (NedResource::isPlaying()) return; + NedMainWindow *main_window = (NedMainWindow *) data; + +@@ -7147,7 +7139,6 @@ + struct paper_info_struct *paper_type = NedResource::getPaperInfo(paper); + w = main_window->m_current_paper->width; + h = main_window->m_current_paper->height; +- p = main_window->m_portrait; + if (main_window->m_portrait != portrait || paper_type->width != w || paper_type->height != h) { + //NedCommandList *dummy = new NedCommandList(main_window); + NedCommandList *command_list = new NedCommandList(main_window); +@@ -7241,18 +7232,14 @@ + } + + int NedMainWindow::setChannelFromCursor() { +- GdkDisplay *display = NULL; + NedStaff *staff; + double dummy1; + int dummy2; + gint x=0, y=0; + GList *lptr; + bool found = false; +- GdkScreen *screen = NULL; + + gtk_widget_get_pointer(m_drawing_area, &x, &y); +- display = gdk_display_get_default(); +- screen = gdk_display_get_default_screen(display); + for (lptr = g_list_first(m_pages); lptr; lptr = g_list_next(lptr)) { + if (((NedPage *) lptr->data)->findLine(x, y, &dummy1, &dummy2, &dummy1, &staff)) { + found = true; break; +Index: nted/resource.cpp +=================================================================== +--- nted.orig/resource.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/resource.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -2676,9 +2676,9 @@ + void NedResource::handleDSalCoda(bool da_capo) { + GList *segno = NULL, *dal_segno_al_coda = NULL, *al_coda = NULL, *coda = NULL; + unsigned long long segno_time = 0, dal_segno_al_coda_time = 0, al_coda_time = 0, coda_time = 0; +- GList *lptr1, *lptr2, *lptr3; ++ GList *lptr1, *lptr2; + GList *repeat_part; +- bool repeat_found, al_coda_found, inside_repeat, before_segno_al_coda, sequ_error; ++ bool inside_repeat, before_segno_al_coda, sequ_error; + unsigned short repeat_signal = (da_capo ? SEGNO_D_CAPO_AL_CODA : SEGNO_D_S_AL_CODA); + + for (lptr1 = g_list_first(m_midi_events); lptr1; lptr1 = g_list_next(lptr1)) { +@@ -2699,7 +2699,6 @@ + } + else { + for (lptr1 = g_list_last(m_midi_events); lptr1; lptr1 = g_list_previous(lptr1)) { +- if (lptr1 == dal_segno_al_coda) repeat_found = true; + lptr2 = g_list_first(((MidiListStruct *) lptr1->data)->notes); + for (; lptr2; lptr2 = g_list_next(lptr2)) { + if ((((MidiEventStruct *) lptr2->data)->segno_sign & SEGNO_SIGN) != 0 && +@@ -2715,7 +2714,6 @@ + + sequ_error = false; + inside_repeat = false; +- al_coda_found = false; + inside_repeat = false; + for (lptr1 = g_list_last(m_midi_events); !sequ_error && lptr1; lptr1 = g_list_previous(lptr1)) { + if (lptr1 == segno) break; +@@ -2789,7 +2787,6 @@ + (((MidiEventStruct *) lptr2->data)->type & NOTE_MASK) == SND_SEQ_EVENT_NOTEON) { // eventually with PSEUDO2_FLAG (rest) + coda = lptr1; + coda_time = ((MidiEventStruct *) lptr2->data)->midi_time; +- lptr3 = g_list_previous(lptr1); + break; + } + } +Index: nted/staff.cpp +=================================================================== +--- nted.orig/staff.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/staff.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -1023,7 +1023,7 @@ + } + + void NedStaff::prepareReplay(bool with_keysig) { +- int i, j; ++ int i; + GList *lptr; + + for (i = 0; i < VOICE_COUNT; i++) { +Index: nted/voice.cpp +=================================================================== +--- nted.orig/voice.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/voice.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -598,7 +598,6 @@ + int minpos = -1; + unsigned long long offs; + int half_offset; +- int num_elements_to_delete = 1; + int clef = TREBLE_CLEF, keysig_so_far, octave_shift; + bool greater_than_last; + GList *min_pos_ptr = NULL; +@@ -764,7 +763,6 @@ + sum_of_chords_and_rests_to_delete -= chord_or_rest->getDuration(); + if (chords_and_rests_to_delete != NULL) { + command_list->addCommand(new NedDeleteChordOrRestGroupCommand(this, chords_and_rests_to_delete)); +- num_elements_to_delete = g_list_length(chords_and_rests_to_delete); + } + command_list->addCommand(new NedInsertChordOrRestCommand(this, minpos++, chord_or_rest)); + last_tupleted_chord_or_rest = chord_or_rest; +@@ -1126,7 +1124,6 @@ + unsigned int duration; + NedDeleteChordOrRestGroupCommand *command; + NedMeasure *measure = NULL; +- bool only_rests = true; + bool measure_start_seen = false; + + start_ptr = g_list_first(items); +@@ -1170,7 +1167,6 @@ + if (element->getSystem() != the_system) continue; + if (element->getStaff() != m_staff) continue; + if (element->getVoice() != this) continue; +- if (!element->isRest()) only_rests = false; + //measure = getSystem()->getMeasure(element->getMidiTime()); + measure = element->m_measure; + if (element->getMidiTime() == measure->midi_start) { +@@ -1254,14 +1250,13 @@ + unsigned long long offs; + bool was_last_in_tuplet; + NedTuplet *tuplet_ptr; +- int tuplet_val, tuplet_val_raw; ++ int tuplet_val; + int new_dot_count = NedResource::getDotCount(); + lptr = g_list_find(m_chord_or_rests, chord_or_rest); + if (lptr == NULL) { + return FALSE; + } + tuplet_val = chord_or_rest->getTupletVal(); +- tuplet_val_raw = chord_or_rest->getTupletValRaw(); + was_last_in_tuplet = chord_or_rest->hasLastTupletFlag(); + chord_or_rest->setLastTupletFlag(FALSE); + new_duration = NedChordOrRest::computeDuration(NedResource::getCurrentLength(), NedResource::getDotCount(), chord_or_rest->getTupletVal()); +@@ -1356,7 +1351,6 @@ + NedChordOrRest *chord_or_rest = NULL, *last_tupleted_chord_or_rest; + int minpos; + GList *min_pos_ptr; +- int num_elements_to_delete; + unsigned long long new_chords_midi_end_time; + unsigned long long ref_duration; + int num_additional_rests; +@@ -1406,7 +1400,6 @@ + } + if (chords_and_rests_to_delete != NULL) { + command_list->addCommand(new NedDeleteChordOrRestGroupCommand(this, chords_and_rests_to_delete)); +- num_elements_to_delete = g_list_length(chords_and_rests_to_delete); + } + command_list->addCommand(new NedSetToTupletCommand(templ, tuplet_val)); + num_additional_rests = (method == 1) ? tuplet_val - 2 : tuplet_val - 1; +Index: nted/chordorrest.cpp +=================================================================== +--- nted.orig/chordorrest.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/chordorrest.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -1185,7 +1185,6 @@ + + void NedChordOrRest::setLength(int length) { + m_length = length; +- unsigned int upbeat; + unsigned int measure_length; + if (m_length == WHOLE_NOTE) { + if (m_voice->getVoiceNumber() > 0) { +@@ -1194,7 +1193,6 @@ + } + else if (m_midi_time == 0 && getMainWindow()->getUpBeatInverse() > 0) { + measure_length = getMainWindow()->getNumerator() * WHOLE_NOTE / getMainWindow()->getDenominator(); +- upbeat = measure_length - getMainWindow()->getUpBeatInverse(); + if (m_voice->getVoiceNumber() > 0 && getDuration() == measure_length) { + m_is_hidden = TRUE; + } +@@ -3566,7 +3564,7 @@ + } + + switch (ftext->m_font_weight) { +- case CAIRO_FONT_WEIGHT_BOLD: fprintf(fp, "%d ", WRITTEN_WEIGHT_BOLD); break; ++ case PANGO_WEIGHT_BOLD: fprintf(fp, "%d ", WRITTEN_WEIGHT_BOLD); break; + default: fprintf(fp, "%d ", WRITTEN_WEIGHT_NORMAL); break; + } + fprintf(fp, " ) "); +@@ -3617,10 +3615,6 @@ + + void NedChordOrRest::prepareMutedReplay() { + GList *lptr; +- int staff_nr; +- struct staff_context_str *contexts; +- staff_nr = getStaff()->getStaffNumber(); +- contexts = getMainWindow()->m_staff_contexts; + + for (lptr = g_list_first(m_freedisp); lptr; lptr = g_list_next(lptr)) { + if (((NedFreeReplaceable *) lptr->data)->getType() == FREE_PLACEABLE_TEMPO) { +@@ -3762,7 +3756,7 @@ + GList *lptr; + bool force_length = false; + char restchar; +- int dotcount, tremolo; ++ int dotcount, tremolo = 0; + unsigned int duration, len2; + char Str[100], Str2[100]; + int i; +Index: nted/note.cpp +=================================================================== +--- nted.orig/note.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/note.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -581,7 +581,6 @@ + + + void NedNote::removeUnneededAccidental(int clef, int keysig, int octave_shift) { +- int p; + int offs = 0; + char offs_array[OFFS_ARRAY_SIZE]; + +@@ -595,7 +594,6 @@ + case TENOR_CLEF: offs = TENOR_PITCH_OFFS; break; + case SOPRAN_CLEF: offs = SOPRAN_PITCH_OFFS; break; + } +- p = lineToPitch[m_line+offs].pitch + octave_shift; + memset(offs_array, 0, sizeof(offs_array)); + getStaff()->findAccidentals(offs_array, m_chord_or_rest->m_measure, m_chord_or_rest->getMidiTime(), false); + switch (m_status & ACCIDENTAL_MASK) { +@@ -1285,8 +1283,6 @@ + int pitch; + int line; + bool flat; +- staff_context_str *context; +- context = &(getMainWindow()->m_staff_contexts[getStaff()->getStaffNumber()]); + getStaff()->getCurrentClefAndKeysig(m_chord_or_rest->getMidiTime(), &clef, &keysig, &octave_shift); + if (clef == NEUTRAL_CLEF3) { + exportLilyPondDrums(fp); +Index: nted/tuplet.cpp +=================================================================== +--- nted.orig/tuplet.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/tuplet.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -140,16 +140,15 @@ + } + + void NedTuplet::reconfigureLast() { +- GList *lptr, *maxmidichordorrest; ++ GList *lptr; + unsigned int maxmiditime; + + ((NedChordOrRest *) g_list_first(m_chords)->data)->getVoice()->assignMidiTimes(); //recompute MIDI Times +- maxmidichordorrest = lptr = g_list_first(m_chords); ++ lptr = g_list_first(m_chords); + maxmiditime = ((NedChordOrRest *) lptr->data)->getMidiTime(); + for (lptr = g_list_next(lptr); lptr; lptr = g_list_next(lptr)) { + if (((NedChordOrRest *) lptr->data)->getMidiTime() > maxmiditime) { + maxmiditime = ((NedChordOrRest *) lptr->data)->getMidiTime(); +- maxmidichordorrest = lptr; + } + } + for (lptr = g_list_first(m_chords); lptr; lptr = g_list_next(lptr)) { +Index: nted/clipboard.cpp +=================================================================== +--- nted.orig/clipboard.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/clipboard.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -64,7 +64,7 @@ + element->from_staff->deleteStaffElements(false, element->chords_or_rests_to_move, m_reftime, m_duration); + if (!m_delete_only) { + if (element->to_staff == NULL) { +- printf("element = 0x%x\n", element); fflush(stdout); ++ printf("element = 0x%p\n", element); fflush(stdout); + NedResource::Abort("element->to_staff == NULL"); + } + element->to_staff->insertIntoStaff(element->chords_or_rests_to_move, m_duration); +Index: nted/midiexport.cpp +=================================================================== +--- nted.orig/midiexport.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/midiexport.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -349,7 +349,7 @@ + + void NedMidiExport::writeTrack(GList *midi_events, int track_nr, int num, int denom) { + GList *lptr1, *lptr2; +- unsigned long long myTime, lastEventTime = 0, newlasteventtime = 0; ++ unsigned long long lastEventTime = 0, newlasteventtime = 0; + int channel = m_main_window->m_staff_contexts[track_nr].m_midi_channel; + long pos1, pos0, length; + bool time_written; +@@ -359,8 +359,6 @@ + unsigned int textlen = 0; + int lyrics_idx; + +- myTime = 0; +- + writeString(strdup("MTrk")); + pos0 = ftell(m_midiout); + writeDWord(0); +Index: nted/positionarray.cpp +=================================================================== +--- nted.orig/positionarray.cpp 2011-05-19 22:47:43.000000000 +0200 ++++ nted/positionarray.cpp 2011-05-19 22:47:48.000000000 +0200 +@@ -203,7 +203,6 @@ + NedNote **notes_with_accidentals = (NedNote **) alloca(MAX_NOTES_PER_WITH_ACCIDENTALS_STAFF * m_staff_count * sizeof(NedNote *)); + NedNote **nptr; + unsigned int *num_notes_with_accidentals_per_staff = (unsigned int *) alloca(m_staff_count * sizeof(unsigned int)); +- unsigned int accidental_columns; + double acc_d; + + memset(num_notes_with_accidentals_per_staff, 0, m_staff_count * sizeof(unsigned int)); +@@ -222,7 +221,6 @@ + } + } + +- accidental_columns = 0; + for (i = 0; i < m_staff_count; i++) { + nptr = notes_with_accidentals + MAX_NOTES_PER_WITH_ACCIDENTALS_STAFF * i; + acc_places[0] = acc_places[1] = acc_places[2] = acc_places[3] = -10000; diff -Nru nted-1.10.18/debian/README.source nted-1.10.18/debian/README.source --- nted-1.10.18/debian/README.source 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/README.source 2011-05-17 22:01:47.000000000 +0000 @@ -19,65 +19,3 @@ The NtEd online help uses yelp and DocBook files whereas dwww needs the HTML files. - -==================================== -HOW TO PATCH UPSTREAM SOURCE CODE -==================================== - -This package uses quilt to manage all modifications to the upstream -source. Changes are stored in the source package as diffs in -debian/patches and applied during the build. - -To configure quilt to use debian/patches instead of patches, you want -either to export QUILT_PATCHES=debian/patches in your environment -or use this snippet in your ~/.quiltrc: - - for where in ./ ../ ../../ ../../../ ../../../../ ../../../../../; do - if [ -e ${where}debian/rules -a -d ${where}debian/patches ]; then - export QUILT_PATCHES=debian/patches - fi - done - -To get the fully patched source after unpacking the source package, cd to -the root level of the source package and run: - - quilt push -a - -The last patch listed in debian/patches/series will become the current -patch. - -To add a new set of changes, first run quilt push -a, and then run: - - quilt new - -where is a descriptive name for the patch, used as the filename in -debian/patches. Then, for every file that will be modified by this patch, -run: - - quilt add - -before editing those files. You must tell quilt with quilt add what files -will be part of the patch before making changes or quilt will not work -properly. After editing the files, run: - - quilt refresh - -to save the results as a patch. - -Alternately, if you already have an external patch and you just want to -add it to the build system, run quilt push -a and then: - - quilt import -P /path/to/patch - quilt push -a - -(add -p 0 to quilt import if needed). as above is the filename to -use in debian/patches. The last quilt push -a will apply the patch to -make sure it works properly. - -To remove an existing patch from the list of patches that will be applied, -run: - - quilt delete - -You may need to run quilt pop -a to unapply patches first before running -this command. diff -Nru nted-1.10.18/debian/rules nted-1.10.18/debian/rules --- nted-1.10.18/debian/rules 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/rules 2011-05-17 22:37:49.000000000 +0000 @@ -1,66 +1,14 @@ #!/usr/bin/make -f # -*- makefile -*- -# Sample debian/rules that uses debhelper. -# -# This file was originally written by Joey Hess and Craig Small. -# As a special exception, when this file is copied by dh-make into a -# dh-make output file, you may use that output file without restriction. -# This special exception was added by Craig Small in version 0.37 of dh-make. -# -# Modified to make a template file for a multi-binary package with separated -# build-arch and build-indep targets by Bill Allombert 2001 - -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 - -# This has to be exported to make some magic below work. -export DH_OPTIONS - -#let's help configure to figure out our host/build system -DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) -DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) -DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) -ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE)) - CONFFLAGS += --build $(DEB_HOST_GNU_TYPE) -else - CONFFLAGS += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE) -endif CONFFLAGS += --prefix=/usr -# Preserving doc//.po from build changes so that the -# source package remains the same after two builds in a row -DOC_LANGUAGES := $(shell grep '^SUBDIRS' $(CURDIR)/doc/Makefile.am | sed 's/^.* docimages en //') %: - dh --with quilt $@ + dh $@ override_dh_auto_configure: - touch aclocal.m4 - touch config.h.in - touch configure - find $(CURDIR) -name Makefile.in -exec touch {} \; + autoreconf YELP=/usr/bin/yelp dh_auto_configure - # See DOC_LANGUAGES - set -e; for DL in $(DOC_LANGUAGES); do \ - /usr/bin/test -f $(CURDIR)/doc/$$DL/$$DL.po.keep || cp -a $(CURDIR)/doc/$$DL/$$DL.po $(CURDIR)/doc/$$DL/$$DL.po.keep; \ - done - # generated debian/nted-doc.install - set -e; for DIR in docimages en $(DOC_LANGUAGES); do \ - echo "debian/tmp/usr/share/doc/nted/$$DIR" >> $(CURDIR)/debian/nted-doc.install; \ - done - -override_dh_clean: - # See DOC_LANGUAGES - set -e; for DL in $(DOC_LANGUAGES); do \ - ( /usr/bin/test ! -f $(CURDIR)/doc/$$DL/$$DL.po.keep || mv -f $(CURDIR)/doc/$$DL/$$DL.po.keep $(CURDIR)/doc/$$DL/$$DL.po); \ - done - rm -f $(CURDIR)/debian/nted-doc.install - dh_clean - -override_dh_install: - dh_install - # Remove examples: they are handled by debian/nted.examples - rm -fr $(CURDIR)/debian/nted/usr/share/nted/examples/ override_dh_compress: dh_compress -X.docbook diff -Nru nted-1.10.18/debian/source/format nted-1.10.18/debian/source/format --- nted-1.10.18/debian/source/format 2011-05-31 08:01:27.000000000 +0000 +++ nted-1.10.18/debian/source/format 2011-05-31 08:01:28.000000000 +0000 @@ -1 +1 @@ -1.0 +3.0 (quilt) diff -Nru nted-1.10.18/debian/source/options nted-1.10.18/debian/source/options --- nted-1.10.18/debian/source/options 1970-01-01 00:00:00.000000000 +0000 +++ nted-1.10.18/debian/source/options 2011-05-17 21:47:32.000000000 +0000 @@ -0,0 +1,2 @@ +# Ignoring files auto-generated by autoreconf and localization +extend-diff-ignore = '(^|/)(aclocal\.m4|config\.h\.in|Makefile\.in|configure|[^/]*\.po)$'