• Antelope Release 5.9 Mac OS X 10.13.2 2019-05-01

 

NAME

BQViewport - BRTT Qt graphics extension for establishing a viewport

SYNOPSIS


$(QTNATIVELIBS) -lbqplot_native -lbanner -lbrttutil -lbumapdata $(DBLIBS) $(TRLIBS)

#include "BQ.h"

DESCRIPTION

BQViewport objects are necessary adjuncts to any of the other bqplot graphics extension objects. These objects will anchor viewport "frames" into QWidget parent objects. A viewport can include margins around the actual data viewport for displaying graph labels and titles. A BQViewport object can be configured to be strictly invisible, meaning the viewport itself will cause no graphics to be rendered, or it can be configured to paint in background colors before the other associated objects are rendered. Note that multiple viewports can occupy the same space in a parent widget. In the following documentation, when we say "viewport frame" we are referring to the entire rectangular viewport area including margins for making axes and title displays. When we refer to "viewport window" we are referring to only the inner portion of the viewport frame inside of the margins that will contain the actual data.

This class inherits the BQConfigure class which is itself a subclass of the BUConfigure class with extensions to process Qt colors and fonts. The configure methods are implemented in the BUConfigure parent (see BUConfigure(3)).

INHERITS FROM

QWidget, BQViewportItem, BQConfigure

CONSTRUCTOR

BQViewport(QWidget *parent, int make_parent_layout=1);

Where parent is the Qt parent widget. If make_parent_layout is set, then a new QGridLayout object is created and used to set the parent's layout to hold and completely fill the new BQViewport object, otherwise the layout must be done by by the application programmer.

METHODS INHERITED FROM BQConfigure

METHODS INHERITED FROM BQViewportItem

Other BQViewportItem methods can be called but are not normally necessary for this object.

BQViewport METHODS

OBJECT CONFIGURATION PARAMETERS

DEFAULT EVENT INTERACTION

BQViewport objects can pan, zoom and center the viewport window according to mouse and keyboard events when the default_event_interaction configuration parameter is set to yes. Left mouse button click and drag will cause the viewport to pan. If the c key is pressed, then the viewport will change so that the world coordinates at the mouse position when the c key was pressed are panned to the center of the viewport. If i or I keys are pressed the viewport is zoomed in. If o or O keys are pressed the viewport is zoomed out. Shift left mouse button click and drag will make a rubber band window that will be zoomed into when the button is released. Shift right mouse button click and drag will make a rubber band window that will be zoomed out of when the button is released. The mouse wheel will also causing zooming in and out in the normal fashion.

SEE ALSO

bqplot(3), BQViewportItem(3), BQConfigure(3), BQLayer(3)

AUTHOR

Danny Harvey, BRTT