GNU Octave 10.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 
Loading...
Searching...
No Matches
gh_manager Class Reference

#include "gh-manager.h"

Public Types

typedef std::pair< uint8NDArray, std::string > latex_data
 

Public Member Functions

 gh_manager (octave::interpreter &interp)
 
void close_all_figures ()
 
graphics_handle current_figure () const
 
void enable_event_processing (bool enable=true)
 
void execute_callback (const graphics_handle &h, const octave_value &cb, const octave_value &data=Matrix())
 
void execute_callback (const graphics_handle &h, const std::string &name, const octave_value &data=Matrix())
 
void execute_listener (const graphics_handle &h, const octave_value &l)
 
Matrix figure_handle_list (bool show_hidden=false)
 
void free (const graphics_handle &h, bool from_root=false)
 
graphics_handle get_handle (bool integer_figure_handle)
 
latex_data get_latex_data (const std::string &key) const
 
graphics_object get_object (const graphics_handle &h) const
 
graphics_object get_object (double val) const
 
octave::mutex graphics_lock ()
 
Matrix handle_list (bool show_hidden=false)
 
bool is_handle_visible (const graphics_handle &h) const
 
void lock ()
 
graphics_handle lookup (const octave_value &val) const
 
graphics_handle lookup (double val) const
 
graphics_handle make_figure_handle (double val, bool notify_toolkit=true)
 
graphics_handle make_graphics_handle (const std::string &go_name, const graphics_handle &p, bool integer_figure_handle=false, bool call_createfcn=true, bool notify_toolkit=true)
 
void pop_figure (const graphics_handle &h)
 
void post_callback (const graphics_handle &h, const std::string &name, const octave_value &data=Matrix())
 
void post_event (const graphics_event &e)
 
void post_function (graphics_event::event_fcn fcn, void *fcn_data=nullptr)
 
void post_set (const graphics_handle &h, const std::string &name, const octave_value &value, bool notify_toolkit=true, bool redraw_figure=false)
 
int process_events (bool force=false)
 
void push_figure (const graphics_handle &h)
 
void renumber_figure (const graphics_handle &old_gh, const graphics_handle &new_gh)
 
void restore_gcbo ()
 
void set_latex_data (const std::string &key, latex_data val)
 
bool try_lock ()
 
void unlock ()
 

Detailed Description

Definition at line 36 of file gh-manager.h.

Member Typedef Documentation

◆ latex_data

typedef std::pair<uint8NDArray , std::string > gh_manager::latex_data

Definition at line 40 of file gh-manager.h.

Constructor & Destructor Documentation

◆ gh_manager()

gh_manager::gh_manager ( octave::interpreter &  interp)

Definition at line 228 of file gh-manager.cc.

Member Function Documentation

◆ close_all_figures()

void gh_manager::close_all_figures ( )

◆ current_figure()

graphics_handle gh_manager::current_figure ( ) const
inline

Definition at line 94 of file gh-manager.h.

◆ enable_event_processing()

void gh_manager::enable_event_processing ( bool  enable = true)

Definition at line 686 of file gh-manager.cc.

◆ execute_callback() [1/2]

◆ execute_callback() [2/2]

void gh_manager::execute_callback ( const graphics_handle h,
const std::string &  name,
const octave_value data = Matrix () 
)
inline

Definition at line 150 of file gh-manager.h.

Referenced by close_figure(), execute_listener(), and F__go_execute_callback__().

◆ execute_listener()

void gh_manager::execute_listener ( const graphics_handle h,
const octave_value l 
)

Definition at line 363 of file gh-manager.cc.

References execute_callback(), and post_event().

◆ figure_handle_list()

Matrix gh_manager::figure_handle_list ( bool  show_hidden = false)
inline

Definition at line 131 of file gh-manager.h.

References Matrix::resize().

Referenced by close_all_figures(), F__go_figure_handles__(), and Fdrawnow().

◆ free()

void gh_manager::free ( const graphics_handle h,
bool  from_root = false 
)

◆ get_handle()

graphics_handle gh_manager::get_handle ( bool  integer_figure_handle)

Definition at line 50 of file gh-manager.cc.

Referenced by make_graphics_handle().

◆ get_latex_data()

latex_data gh_manager::get_latex_data ( const std::string &  key) const
inline

Definition at line 212 of file gh-manager.h.

◆ get_object() [1/2]

graphics_object gh_manager::get_object ( const graphics_handle h) const
inline

Definition at line 73 of file gh-manager.h.

References octave_handle::ok().

◆ get_object() [2/2]

◆ graphics_lock()

◆ handle_list()

Matrix gh_manager::handle_list ( bool  show_hidden = false)
inline

Definition at line 107 of file gh-manager.h.

References Matrix::resize(), and octave_handle::value().

Referenced by F__go_handles__().

◆ is_handle_visible()

bool gh_manager::is_handle_visible ( const graphics_handle h) const
inline

Definition at line 189 of file gh-manager.h.

◆ lock()

void gh_manager::lock ( )
inline

Definition at line 125 of file gh-manager.h.

Referenced by Fdrawnow().

◆ lookup() [1/2]

graphics_handle gh_manager::lookup ( const octave_value val) const
inline

◆ lookup() [2/2]

◆ make_figure_handle()

graphics_handle gh_manager::make_figure_handle ( double  val,
bool  notify_toolkit = true 
)

Definition at line 299 of file gh-manager.cc.

Referenced by F__go_figure__().

◆ make_graphics_handle()

graphics_handle gh_manager::make_graphics_handle ( const std::string &  go_name,
const graphics_handle p,
bool  integer_figure_handle = false,
bool  call_createfcn = true,
bool  notify_toolkit = true 
)

Definition at line 243 of file gh-manager.cc.

References error(), get_handle(), get_object(), and make_graphics_object_from_type().

Referenced by F__go_figure__().

◆ pop_figure()

void gh_manager::pop_figure ( const graphics_handle h)

Definition at line 326 of file gh-manager.cc.

Referenced by push_figure().

◆ post_callback()

void gh_manager::post_callback ( const graphics_handle h,
const std::string &  name,
const octave_value data = Matrix () 
)

Definition at line 494 of file gh-manager.cc.

References get_object(), and post_event().

Referenced by F__go_post_callback__().

◆ post_event()

void gh_manager::post_event ( const graphics_event &  e)

Definition at line 486 of file gh-manager.cc.

Referenced by execute_listener(), post_callback(), post_function(), and post_set().

◆ post_function()

void gh_manager::post_function ( graphics_event::event_fcn  fcn,
void *  fcn_data = nullptr 
)

Definition at line 529 of file gh-manager.cc.

References post_event().

◆ post_set()

void gh_manager::post_set ( const graphics_handle h,
const std::string &  name,
const octave_value value,
bool  notify_toolkit = true,
bool  redraw_figure = false 
)

Definition at line 537 of file gh-manager.cc.

References post_event().

◆ process_events()

int gh_manager::process_events ( bool  force = false)

Definition at line 548 of file gh-manager.cc.

References Fdrawnow(), and Vdrawnow_requested.

Referenced by F__get_frame__(), Fdrawnow(), and sleep().

◆ push_figure()

void gh_manager::push_figure ( const graphics_handle h)

Definition at line 318 of file gh-manager.cc.

References pop_figure().

Referenced by F__go_figure__().

◆ renumber_figure()

void gh_manager::renumber_figure ( const graphics_handle old_gh,
const graphics_handle new_gh 
)

Definition at line 154 of file gh-manager.cc.

References error(), and octave_handle::value().

◆ restore_gcbo()

void gh_manager::restore_gcbo ( )

Definition at line 352 of file gh-manager.cc.

Referenced by execute_callback().

◆ set_latex_data()

void gh_manager::set_latex_data ( const std::string &  key,
latex_data  val 
)
inline

Definition at line 224 of file gh-manager.h.

◆ try_lock()

bool gh_manager::try_lock ( )
inline

Definition at line 127 of file gh-manager.h.

◆ unlock()

void gh_manager::unlock ( )
inline

Definition at line 129 of file gh-manager.h.

Referenced by Fdrawnow(), and sleep().


The documentation for this class was generated from the following files: