Ticket #3632: 0001-Fixed-screen-height-SL-3632.patch

File 0001-Fixed-screen-height-SL-3632.patch, 1.5 KB (added by humitos, 12 years ago)
  • library.py

    From faa1eefa6271637f73997208efd24c245df55c7c Mon Sep 17 00:00:00 2001
    Message-Id: <faa1eefa6271637f73997208efd24c245df55c7c.1337797268.git.humitos@gmail.com>
    From: Manuel Kaufmann <humitos@gmail.com>
    Date: Wed, 23 May 2012 15:18:44 -0300
    Subject: [PATCH InfoSlicer] Fixed screen height SL #3632
    
    Use the correct way to calculate the height of the screen to avoid
    overlap:
    
    gtk.gdk.screen_height() - sugar.graphics.style.GRID_CELL_SIZE
    
    Signed-off-by: Manuel Kaufmann <humitos@gmail.com>
    ---
     library.py |    6 ++++--
     1 file changed, 4 insertions(+), 2 deletions(-)
    
    diff --git a/library.py b/library.py
    index 86bde44..a317f99 100644
    a b class View(gtk.EventBox): 
    119119        wiki_box.pack_start(wiki)
    120120        wiki_box.pack_start(self.progress, False)
    121121        wiki_box.set_size_request(gtk.gdk.screen_width()/4*3,
    122                 gtk.gdk.screen_height()/2)
     122                gtk.gdk.screen_height()/2 - style.GRID_CELL_SIZE / 2)
    123123
    124124        custom_widget = Reading_View()
    125125        custom = gtk.Notebook()
    class View(gtk.EventBox): 
    127127        custom.props.show_tabs = False
    128128        custom.append_page(custom_stub)
    129129        custom.append_page(custom_widget)
     130        # custom.set_size_request(gtk.gdk.screen_width()/4*3,
     131        #         gtk.gdk.screen_height()/2 - 55)
    130132        custom.set_size_request(gtk.gdk.screen_width()/4*3,
    131                 gtk.gdk.screen_height()/2)
     133                gtk.gdk.screen_height()/2 - style.GRID_CELL_SIZE / 2)
    132134
    133135        # workspace
    134136