void Canvas::resize( const wxSize& new_size ) { contents.reset( NULL ); contents.reset( new wxImage( new_size.GetWidth(), new_size.GetHeight() ) ); wxScrolledWindow::SetVirtualSize( canvas_coords( new_size ).GetSize() ); zoom_to( canvas_coords( new_size ) ); }
void GLCanvas::reset_zoom_pan() { zoom_to(1) ; pan(-(m_window[LEFT] + m_window[RIGHT])/2, -(m_window[BOTTOM] + m_window[TOP])/2) ; }
GLADE_CALLBACK void diagwin_t::on_zoom_out_activate() { _log.debug("diagwin_t::on_zoom_out_activate\n"); zoom_to(zoom_/2.0); }
void Scrollable::scale_to(DimensionName, float fraction_visible) { zoom_to(fraction_visible); }