1

Ok, This might be helpful to someone.

In Ubuntu 15.10 guake has changed a little bit. To change your terminal to the right monitor you have to edit:

/usr/lib/python2.7/dist-packages/guake/guake_app.py

then change in line 831:

window_rect = screen.get_monitor_geometry(monitor)

by:

window_rect = screen.get_monitor_geometry(1)

kill and restart guake

Anyone knows a way to do this less hacky?

0

I'm on Linux Mint and the following solution worked to me (it should work on Ubuntu as well). Edit your /usr/bin/guake/ file replacing the get_final_window_rect method with this:

def get_final_window_rect(self):
    """Gets the final size of the main window of guake. The height
    is the window_height property, width is window_width and the
    horizontal alignment is given by window_alignment.
    """
    screen = self.window.get_screen()
    height = self.client.get_int(KEY('/general/window_height'))
    width = 100
    halignment = self.client.get_int(KEY('/general/window_halignment'))

    # future we might create a field to select which monitor you
    # wanna use
    #monitor = 0 # use the left most monitor
    monitor = screen.get_n_monitors() - 1 # use the right most monitor

    monitor_rect = screen.get_monitor_geometry(monitor)
    window_rect = monitor_rect.copy()
    window_rect.height = window_rect.height * height / 100
    window_rect.width = window_rect.width * width / 100

    if width < monitor_rect.width:
        if halignment == ALIGN_CENTER:
            window_rect.x = monitor_rect.x + (monitor_rect.width - window_rect.width) / 2
        elif halignment == ALIGN_LEFT:
            window_rect.x = monitor_rect.x
        elif halignment == ALIGN_RIGHT:
            window_rect.x = monitor_rect.x + monitor_rect.width - window_rect.width

    window_rect.y = monitor_rect.y
    return window_rect

I take it from here, but i changed 80 to 100.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.