|
Lines 1613-1620
Link Here
|
| 1613 |
if (window->priv->active_term == screen) |
1613 |
if (window->priv->active_term == screen) |
| 1614 |
return; |
1614 |
return; |
| 1615 |
|
1615 |
|
|
|
1616 |
/* Workaround to remove gtknotebook's feature of computing its size based on |
| 1617 |
* all pages. When the widget is hidden, its size will not be taken into |
| 1618 |
* account. |
| 1619 |
*/ |
| 1620 |
if (window->priv->active_term) |
| 1621 |
{ |
| 1622 |
GtkWidget *old_widget; |
| 1623 |
old_widget = terminal_screen_get_widget (window->priv->active_term); |
| 1624 |
gtk_widget_hide (old_widget); |
| 1625 |
} |
| 1626 |
|
| 1616 |
widget = terminal_screen_get_widget (screen); |
1627 |
widget = terminal_screen_get_widget (screen); |
| 1617 |
|
1628 |
|
|
|
1629 |
/* Make sure that the widget is no longer hidden due to the workaround */ |
| 1630 |
gtk_widget_show (widget); |
| 1631 |
|
| 1618 |
profile = terminal_screen_get_profile (screen); |
1632 |
profile = terminal_screen_get_profile (screen); |
| 1619 |
|
1633 |
|
| 1620 |
if (!GTK_WIDGET_REALIZED (widget)) |
1634 |
if (!GTK_WIDGET_REALIZED (widget)) |
|
Lines 1705-1715
Link Here
|
| 1705 |
TerminalScreen *screen; |
1719 |
TerminalScreen *screen; |
| 1706 |
GtkWidget *menu_item; |
1720 |
GtkWidget *menu_item; |
| 1707 |
int old_grid_width, old_grid_height; |
1721 |
int old_grid_width, old_grid_height; |
| 1708 |
GtkWidget *old_widget; |
1722 |
GtkWidget *old_widget, *new_widget; |
| 1709 |
|
|
|
| 1710 |
old_widget = NULL; |
| 1711 |
old_grid_width = -1; |
| 1712 |
old_grid_height = -1; |
| 1713 |
|
1723 |
|
| 1714 |
if (window->priv->active_term == NULL) |
1724 |
if (window->priv->active_term == NULL) |
| 1715 |
return; |
1725 |
return; |
|
Lines 1725-1741
Link Here
|
| 1725 |
screen = TERMINAL_SCREEN (page_widget); |
1735 |
screen = TERMINAL_SCREEN (page_widget); |
| 1726 |
|
1736 |
|
| 1727 |
g_assert (screen); |
1737 |
g_assert (screen); |
|
|
1738 |
|
| 1739 |
/* This is so that we maintain the same grid */ |
| 1740 |
new_widget = terminal_screen_get_widget (screen); |
| 1741 |
terminal_widget_set_size (new_widget, old_grid_width, old_grid_height); |
| 1728 |
|
1742 |
|
| 1729 |
terminal_window_set_active (window, screen); |
1743 |
terminal_window_set_active (window, screen); |
| 1730 |
|
1744 |
|
| 1731 |
/* This is so we maintain the same grid moving among tabs with |
|
|
| 1732 |
* different fonts. |
| 1733 |
*/ |
| 1734 |
#ifdef DEBUG_GEOMETRY |
| 1735 |
g_fprintf (stderr,"setting size in switch_page handler\n"); |
| 1736 |
#endif |
| 1737 |
terminal_window_set_size_force_grid (window, screen, TRUE, old_grid_width, old_grid_height); |
| 1738 |
|
| 1739 |
update_tab_sensitivity (window); |
1745 |
update_tab_sensitivity (window); |
| 1740 |
|
1746 |
|
| 1741 |
menu_item = screen_get_menuitem (screen); |
1747 |
menu_item = screen_get_menuitem (screen); |