Minsky
|
#include <sheet.h>
Private Member Functions | |
CLASSDESC_ACCESS (Sheet) | |
double | ravelSize () const |
size of ravel in screen coordinates More... | |
Private Attributes | |
ravel::Ravel | inputRavel |
ravel for controlling input value used for populating sheet. Potentially a tensor expression representing ravel manipulation More... | |
civita::TensorPtr | value |
size_t | scrollOffset =0 |
offset for scrolling through higher ranked inputs More... | |
size_t | scrollMax =1 |
offset for scrolling through higher ranked inputs More... | |
size_t | scrollDelta =0 |
offset for scrolling through higher ranked inputs More... | |
std::string | sliceIndicator |
offset for scrolling through higher ranked inputs More... | |
bool | showRavel =false |
offset for scrolling through higher ranked inputs More... | |
ShowSlice | showRowSlice =ShowSlice::head |
whether to elide rows from beginning, end or middle More... | |
ShowSlice | showColSlice =ShowSlice::head |
whether to elide columnss from beginning, end or middle More... | |
double | ravelX (double xx) const |
ravel coordinate from screen coordinate More... | |
double | ravelY (double yy) const |
offset for scrolling through higher ranked inputs More... | |
Sheet () | |
offset for scrolling through higher ranked inputs More... | |
void | operator= (const Sheet &) |
offset for scrolling through higher ranked inputs More... | |
Sheet (const Sheet &) | |
offset for scrolling through higher ranked inputs More... | |
bool | onResizeHandle (float x, float y) const override |
offset for scrolling through higher ranked inputs More... | |
void | drawResizeHandles (cairo_t *cairo) const override |
offset for scrolling through higher ranked inputs More... | |
bool | onRavelButton (float, float) const |
offset for scrolling through higher ranked inputs More... | |
bool | inRavel (float, float) const |
offset for scrolling through higher ranked inputs More... | |
bool | inItem (float, float) const override |
offset for scrolling through higher ranked inputs More... | |
ClickType::Type | clickType (float x, float y) const override |
offset for scrolling through higher ranked inputs More... | |
std::vector< Point > | corners () const override |
offset for scrolling through higher ranked inputs More... | |
bool | contains (float x, float y) const override |
offset for scrolling through higher ranked inputs More... | |
bool | scrollUp () |
offset for scrolling through higher ranked inputs More... | |
bool | scrollDown () |
offset for scrolling through higher ranked inputs More... | |
bool | onKeyPress (int keySym, const std::string &utf8, int state) override |
offset for scrolling through higher ranked inputs More... | |
void | setSliceIndicator () |
offset for scrolling through higher ranked inputs More... | |
void | draw (cairo_t *cairo) const override |
offset for scrolling through higher ranked inputs More... | |
void | computeValue () |
calculates the input value More... | |
void | exportAsCSV (const std::string &filename, bool tabular) const |
export the plotted data as a CSV file More... | |
Additional Inherited Members | |
![]() | |
std::string | classType () const override |
ItemT * | clone () const override |
void | TCL_obj (classdesc::TCL_obj_t &t, const std::string &d) override |
void | RESTProcess (classdesc::RESTProcess_t &rp, const std::string &d) override |
dummy template definition for use with gui executable More... | |
void | RESTProcess (classdesc::RESTProcess_t &rp, const std::string &d) const override |
void | json_pack (classdesc::json_pack_t &j) const override |
ItemT ()=default | |
ItemT (const ItemT &)=default | |
ItemT (ItemT &&)=delete | |
ItemT & | operator= (const ItemT &)=default |
ItemT & | operator= (ItemT &&)=delete |
![]() | |
Item () | |
virtual std::weak_ptr< Port > | ports (std::size_t i) const |
callback to be run when item deleted from group More... | |
std::size_t | portsSize () const |
number of ports More... | |
float | portX (std::size_t i) |
float | portY (std::size_t i) |
bool | contains (const Point &p) const |
void | updateBoundingBox () override |
void | throw_error (const std::string &) const |
mark item on canvas, then throw More... | |
virtual bool | ioVar () const |
indicates this is a group I/O variable More... | |
virtual double | value () const |
current value of output port More... | |
double | rotation () const |
double | rotation (const double &r) |
std::pair< double, bool > | rotationAsRadians () const |
return the rotation as radians, and whether rotation should have additional straight angle added for text that stays upright. More... | |
float | iWidth () const |
float | iWidth (const float &w) |
float | iHeight () const |
float | iHeight (const float &h) |
virtual void | flip () |
rotate icon though 180∘ More... | |
std::string | id () const |
return an id uniquely identifying this item More... | |
virtual float | x () const |
virtual float | y () const |
virtual float | zoomFactor () const |
void | ensureBBValid () const |
float | width () const |
float | height () const |
float | left () const |
float | right () const |
float | top () const |
float | bottom () const |
std::string | bookmarkId () const |
Id of bookmark associated with this. More... | |
void | adjustBookmark () const override |
adjust bookmark list to reflect current configuration More... | |
float | resizeHandleSize () const |
resize handles should be at least a percentage if the icon size (#1025) More... | |
virtual bool | onItem (float x, float y) const |
returns true if (x,y) is on the icon More... | |
virtual void | onMouseDown (float x, float y) |
respond to mouse down events More... | |
virtual void | onMouseUp (float x, float y) |
respond to mouse up events More... | |
virtual bool | onMouseMotion (float x, float y) |
respond to mouse motion events with button pressed More... | |
virtual bool | onMouseOver (float x, float y) |
respond to mouse motion events (hover) without button pressed More... | |
virtual void | onMouseLeave () |
respond to mouse leave events (when mouse leaves item) More... | |
virtual void | deleteAttachedWires () |
delete all attached wires More... | |
virtual bool | visible () const |
whether this item is visible on the canvas. More... | |
void | moveTo (float x, float y) |
virtual void | resize (const LassoBox &b) |
resize this item on the canvas More... | |
virtual float | scaleFactor () const |
factor by which item has been resized More... | |
virtual float | scaleFactor (const float &sf) |
void | dummyDraw () const |
draw into a dummy cairo context, for purposes of calculating port positions More... | |
virtual void | displayTooltip (cairo_t *, const std::string &) const |
display tooltip text, eg on mouseover More... | |
virtual void | updateIcon (double t) |
update display after a step() More... | |
Item (const Item &)=default | |
Item & | operator= (const Item &)=default |
virtual | ~Item () |
void | drawPorts (cairo_t *cairo) const |
virtual std::shared_ptr< Port > | closestOutPort (float x, float y) const |
returns closest output port to x,y More... | |
virtual std::shared_ptr< Port > | closestInPort (float x, float y) const |
virtual std::shared_ptr< Item > | select (float x, float y) const |
returns the variable if point (x,y) is within a visible variable icon, null otherwise. More... | |
void | RESTProcess (classdesc::RESTProcess_t &rp, const std::string &d) override |
runs the RESTProcess descriptor suitable for this type More... | |
void | RESTProcess (classdesc::RESTProcess_t &rp, const std::string &d) const override |
virtual void | displayDelayedTooltip (float x, float y) |
enable extended tooltip help message appropriate for mouse at (x,y) More... | |
virtual void | disableDelayedTooltip () |
virtual bool | editorMode () const |
some items have an editor mode attribute More... | |
virtual void | toggleEditorMode () |
virtual Units | units (bool check=false) const |
compute the dimensional units More... | |
Units | checkUnits () const |
perform units consistency checks More... | |
ItemPtr | itemPtrFromThis () const |
return a shared_ptr to this More... | |
virtual void | destroyFrame () |
destroy any popup windows associated with this More... | |
![]() | |
virtual std::string const & | detailedText () const |
virtual std::string const & | detailedText (const std::string &x) |
virtual std::string const & | tooltip () const |
virtual std::string const & | tooltip (const std::string &x) |
virtual | ~NoteBase ()=default |
![]() | |
static void | drawSelected (cairo_t *cairo) |
![]() | |
float | m_x =0 |
float | m_y =0 |
position in canvas, or within group More... | |
float | m_sf =1 |
scale factor of item on canvas, or within group More... | |
bool | onResizeHandles =false |
set to true to indicate mouse is ovcaler resize handles More... | |
bool | onBorder =false |
true to indicate mouse hovering over border More... | |
std::string | deleteCallback |
BoundingBox | bb |
canvas bounding box. More... | |
![]() | |
bool | mouseFocus =false |
true if target of a mouseover More... | |
bool | selected =false |
true if selected for cut, copy or group operation More... | |
bool | bookmark =false |
Is this item also a bookmark? More... | |
![]() | |
static void | drawResizeHandle (cairo_t *cairo, double x, double y, double sf, double angle) |
![]() | |
double | m_width =10 |
double | m_height =10 |
ItemPortVector | m_ports |
minsky::Item::MemoisedRotator | memoisedRotator |
Sheet::Sheet | ( | ) |
|
inline |
|
private |
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 111 of file sheet.cc.
References minsky::ClickType::inItem, minsky::ClickType::onItem, minsky::ClickType::onResize, and minsky::ClickType::outside.
void Sheet::computeValue | ( | ) |
calculates the input value
Definition at line 222 of file sheet.cc.
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 128 of file sheet.cc.
References minsky::Item::contains().
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 122 of file sheet.cc.
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 293 of file sheet.cc.
References border, minsky::anonymous_namespace{userFunction.cc}::isnan(), M_PI, minsky::minsky(), minsky::Minsky::requestReset(), minsky::str(), and minsky::trimWS().
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 76 of file sheet.cc.
References M_PI.
void Sheet::exportAsCSV | ( | const std::string & | filename, |
bool | tabular | ||
) | const |
export the plotted data as a CSV file
tabular | - if true, the longest dimension is split across columns as a horizontal dimension |
Definition at line 522 of file sheet.cc.
References minsky::VariableValue::exportAsCSV(), and minsky::VariableType::flow.
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 104 of file sheet.cc.
References border.
bool Sheet::inRavel | ( | float | xx, |
float | yy | ||
) | const |
offset for scrolling through higher ranked inputs
Definition at line 96 of file sheet.cc.
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 155 of file sheet.cc.
bool Sheet::onRavelButton | ( | float | xx, |
float | yy | ||
) | const |
offset for scrolling through higher ranked inputs
Definition at line 89 of file sheet.cc.
References border.
|
overridevirtual |
offset for scrolling through higher ranked inputs
Reimplemented from minsky::Item.
Definition at line 66 of file sheet.cc.
|
inline |
|
private |
|
private |
ravel coordinate from screen coordinate
Definition at line 56 of file sheet.cc.
References ravelOffset.
|
private |
offset for scrolling through higher ranked inputs
Definition at line 61 of file sheet.cc.
References ravelOffset.
bool Sheet::scrollDown | ( | ) |
offset for scrolling through higher ranked inputs
Definition at line 144 of file sheet.cc.
bool Sheet::scrollUp | ( | ) |
offset for scrolling through higher ranked inputs
Definition at line 133 of file sheet.cc.
void Sheet::setSliceIndicator | ( | ) |
offset for scrolling through higher ranked inputs
Definition at line 175 of file sheet.cc.
References anonymous_namespace{sheet.cc}::formattedStr().
|
private |
|
private |
|
private |
|
private |
ShowSlice minsky::Sheet::showColSlice =ShowSlice::head |
bool minsky::Sheet::showRavel =false |
ShowSlice minsky::Sheet::showRowSlice =ShowSlice::head |
|
private |
|
private |