[Easytag-mailing] Patch to improve the application in low-resolution computers



Hi!

I don't know if any of you noticed, but in computers with low resolution (like netbooks), Easytag cannot be used properly. This is because the form to edit id3 tags is very big and cannot be resizable.

I send you a little patch for this subject, just adding the possibility to resize that form (with a scrolled window). Just apply to the sources and re-compile. This is the first patch I release on any project, so let me know if there is something wrong.

Thanks in advance

--
Pablo Recio Quijano

Estudiante de Ingeniería Informática (UCA)
Alumno colaborador del Departamento de Lenguajes y Sistemas Informáticos
--- ../easytag-2.1.6 (2)/src/easytag.h	2007-11-28 09:54:35.000000000 +0100
+++ src/easytag.h	2010-04-29 15:49:53.000000000 +0200
@@ -85,6 +85,7 @@
 
 /* TAG Area */
 GtkWidget    *TagFrame;
+GtkWidget    *ScrolledWindow;
 GtkWidget    *TagNoteBook;
 GtkWidget    *TitleEntry;
 GtkWidget    *ArtistEntry;
--- ../easytag-2.1.6 (2)/src/easytag.c	2008-05-22 00:06:00.000000000 +0200
+++ src/easytag.c	2010-04-29 16:36:38.000000000 +0200
@@ -383,7 +383,7 @@
 
     /* Tag */
     TagArea = Create_Tag_Area();
-    gtk_box_pack_start(GTK_BOX(VBox),TagArea,FALSE,FALSE,0);
+    gtk_box_pack_start(GTK_BOX(VBox),TagArea,TRUE,TRUE,0);
 
     /* Vertical pane for Browser Area + FileArea + TagArea */
     MainWindowVPaned = gtk_vpaned_new();
@@ -582,9 +582,15 @@
     TagFrame = gtk_frame_new(_("Tag"));
     gtk_container_set_border_width(GTK_CONTAINER(TagFrame),2);
 
+    /* ScrolledWindow */
+    ScrolledWindow = gtk_scrolled_window_new(NULL, NULL);
+    gtk_container_add(GTK_CONTAINER(TagFrame),ScrolledWindow);
+    gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(ScrolledWindow),
+                                   GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);
+
     /* Box for the notebook (only for setting a border) */
     VBox = gtk_vbox_new(FALSE,0);
-    gtk_container_add(GTK_CONTAINER(TagFrame),VBox);
+    gtk_scrolled_window_add_with_viewport (ScrolledWindow, VBox);
     gtk_container_set_border_width(GTK_CONTAINER(VBox),2);
 
     /*
@@ -592,7 +598,7 @@
      */
     TagNoteBook = gtk_notebook_new();
     gtk_notebook_popup_enable(GTK_NOTEBOOK(TagNoteBook));
-    //gtk_container_add(GTK_CONTAINER(TagFrame),TagNoteBook);
+    // gtk_container_add(GTK_CONTAINER(ScrolledWindow),TagNoteBook);
     gtk_box_pack_start(GTK_BOX(VBox),TagNoteBook,TRUE,TRUE,0);
     gtk_notebook_set_tab_pos(GTK_NOTEBOOK(TagNoteBook),GTK_POS_TOP);
     gtk_notebook_set_show_border(GTK_NOTEBOOK(TagNoteBook),FALSE);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]