Changeset 225

Show
Ignore:
Timestamp:
06/12/06 15:34:33 (2 years ago)
Author:
jordi
Message:

The '%' symbol is now not part of the current zoom's entry.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/MainPter.cxx

    r224 r225  
    253253MainPter::setZoomText (gdouble zoom) 
    254254{ 
    255     gchar *zoomText = g_strdup_printf ("%.3g%%", zoom * 100.0); 
     255    gchar *zoomText = g_strdup_printf ("%.3g", zoom * 100.0); 
    256256    getView ().setZoomText (zoomText); 
    257257    g_free (zoomText); 
  • trunk/src/gtk/MainView.cxx

    r213 r225  
    3737static gint CURRENT_PAGE_WIDTH = 14; 
    3838static gint CURRENT_ZOOM_POS = 8; 
    39 static gint CURRENT_ZOOM_WIDTH = 7
     39static gint CURRENT_ZOOM_WIDTH = 6
    4040 
    4141// Enumerations. 
     
    5151static void main_window_about_box_cb (GtkWidget *, gpointer); 
    5252static void main_window_find_cb (GtkWidget *, gpointer); 
    53 static gboolean main_window_moved_or_resized_cb (GtkWidget *,  
     53static gboolean main_window_moved_or_resized_cb (GtkWidget *, 
    5454                                                 GdkEventConfigure *, gpointer); 
    5555static void main_window_go_to_first_page_cb (GtkWidget *, gpointer); 
     
    519519MainView::sensitiveZoom (gboolean sensitive) 
    520520{ 
    521     gtk_widget_set_sensitive (m_CurrentZoom, sensitive); 
     521    gtk_widget_set_sensitive (GTK_WIDGET (m_CurrentZoomToolItem), sensitive); 
    522522} 
    523523 
     
    533533MainView::sensitiveZoomOut (gboolean sensitive) 
    534534{ 
    535     GtkAction *zoomOut =  
     535    GtkAction *zoomOut = 
    536536        gtk_ui_manager_get_action (m_UIManager, "/MenuBar/ViewMenu/ZoomOut"); 
    537537    gtk_action_set_sensitive (zoomOut, sensitive); 
    538538} 
    539539 
    540 void  
     540void 
    541541MainView::sensitiveZoomFit (gboolean sensitive) 
    542542{ 
    543     GtkAction *zoomFit =  
     543    GtkAction *zoomFit = 
    544544        gtk_ui_manager_get_action (m_UIManager, "/MenuBar/ViewMenu/ZoomFit"); 
    545545    gtk_action_set_sensitive (zoomFit, sensitive); 
     
    784784                      G_CALLBACK (main_window_zoom_cb), m_Pter); 
    785785 
     786    GtkWidget *zoomBox = gtk_hbox_new (FALSE, 3); 
     787    gtk_box_pack_start_defaults (GTK_BOX (zoomBox), m_CurrentZoom); 
     788    gtk_box_pack_start (GTK_BOX (zoomBox), gtk_label_new ("%"), 
     789                        FALSE, FALSE, 0); 
    786790    m_CurrentZoomToolItem = gtk_tool_item_new (); 
    787     gtk_container_add (GTK_CONTAINER (m_CurrentZoomToolItem), m_CurrentZoom); 
     791    gtk_container_add (GTK_CONTAINER (m_CurrentZoomToolItem), zoomBox); 
    788792} 
    789793