/*! \brief Changes the current page. * \par Function Description * This function displays the specified page <B>page</B> in the * window attached to <B>toplevel</B>. * * It changes the <B>toplevel</B>'s current page to <B>page</B>, * draws it and updates the user interface. * * <B>page</B> has to be in the list of PAGEs attached to <B>toplevel</B>. * * \param [in] w_current The toplevel environment. * \param [in] page The page to become current page. */ void x_window_set_current_page (GschemToplevel *w_current, PAGE *page) { GschemPageView *page_view = gschem_toplevel_get_current_page_view (w_current); g_return_if_fail (page != NULL); g_return_if_fail (page_view != NULL); o_redraw_cleanstates (w_current); gschem_page_view_set_page (page_view, page); i_update_menus (w_current); i_set_filename (w_current, page->page_filename); x_pagesel_update (w_current); x_multiattrib_update (w_current); gschem_page_view_update_scroll_adjustments (page_view); gschem_page_view_invalidate_all (page_view); }
/*! \brief Changes the current page. * \par Function Description * This function displays the specified page <B>page</B> in the * window attached to <B>toplevel</B>. * * It changes the <B>toplevel</B>'s current page to <B>page</B>, * draws it and updates the user interface. * * <B>page</B> has to be in the list of PAGEs attached to <B>toplevel</B>. * * \param [in] w_current The toplevel environment. * \param [in] page The page to become current page. */ void x_window_set_current_page (GSCHEM_TOPLEVEL *w_current, PAGE *page) { TOPLEVEL *toplevel = w_current->toplevel; g_return_if_fail (toplevel != NULL); g_return_if_fail (page != NULL); o_redraw_cleanstates (w_current); s_page_goto (toplevel, page); i_update_menus (w_current); i_set_filename (w_current, page->page_filename); x_pagesel_update (w_current); x_multiattrib_update (w_current); x_manual_resize (w_current); x_hscrollbar_update (w_current); x_vscrollbar_update (w_current); o_invalidate_all (w_current); }