Blender  V3.3
Public Attributes | List of all members
v2dScrollerMove Struct Reference

Public Attributes

View2Dv2d
 
ARegionregion
 
char scroller
 
short zone
 
float fac
 
float fac_round
 
float delta
 
float scrollbarwidth
 
int scrollbar_orig
 
int lastx
 
int lasty
 

Detailed Description

Scrollers should behave in the following ways, when clicked on with LMB (and dragged):

  1. 'Handles' on end of 'bubble' - when the axis that the scroller represents is zoomable, enlarge 'cur' rect on the relevant side.
  2. 'Bubble'/'bar' - just drag, and bar should move with mouse (view pans opposite).

In order to make sure this works, each operator must define the following RNA-Operator Props:

Definition at line 1702 of file view2d_ops.cc.

Member Data Documentation

◆ delta

float v2dScrollerMove::delta

amount moved by mouse on axis of interest

Definition at line 1720 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), scroller_activate_invoke(), and scroller_activate_modal().

◆ fac

float v2dScrollerMove::fac

view adjustment factor, based on size of region

Definition at line 1716 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), and scroller_activate_init().

◆ fac_round

float v2dScrollerMove::fac_round

for pixel rounding (avoid visible UI jitter)

Definition at line 1718 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), and scroller_activate_init().

◆ lastx

int v2dScrollerMove::lastx

previous mouse coordinates (in screen coordinates) for determining movement

Definition at line 1728 of file view2d_ops.cc.

Referenced by scroller_activate_init(), and scroller_activate_modal().

◆ lasty

int v2dScrollerMove::lasty

Definition at line 1728 of file view2d_ops.cc.

Referenced by scroller_activate_init(), and scroller_activate_modal().

◆ region

ARegion* v2dScrollerMove::region

region that the scroller is in

Definition at line 1706 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), and scroller_activate_init().

◆ scrollbar_orig

int v2dScrollerMove::scrollbar_orig

initial location of scrollbar x/y, mouse relative

Definition at line 1725 of file view2d_ops.cc.

Referenced by scroller_activate_init(), and scroller_activate_invoke().

◆ scrollbarwidth

float v2dScrollerMove::scrollbarwidth

width of the scrollbar itself, used for page up/down clicks

Definition at line 1723 of file view2d_ops.cc.

Referenced by scroller_activate_init(), and scroller_activate_modal().

◆ scroller

char v2dScrollerMove::scroller

scroller that mouse is in ('h' or 'v')

Definition at line 1709 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), scroller_activate_init(), scroller_activate_invoke(), and scroller_activate_modal().

◆ v2d

View2D* v2dScrollerMove::v2d

View2D data that this operation affects

Definition at line 1704 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), scroller_activate_exit(), and scroller_activate_init().

◆ zone

short v2dScrollerMove::zone

-1 is min zoomer, 0 is bar, 1 is max zoomer

Definition at line 1713 of file view2d_ops.cc.

Referenced by scroller_activate_apply(), scroller_activate_init(), scroller_activate_invoke(), and scroller_activate_modal().


The documentation for this struct was generated from the following file: