Cadabra
Computer algebra system for field theory problems
Loading...
Searching...
No Matches
Classes | Public Member Functions | Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
cadabra::TeXView Class Reference

#include <TeXView.hh>

Inheritance diagram for cadabra::TeXView:

Classes

class  TeXArea
 

Public Member Functions

 TeXView (TeXEngine &, DTree::iterator, int hmargin=25)
 
virtual ~TeXView ()
 
void set_is_error (bool)
 
void update_image ()
 Update the TeX image.
 
void dim (bool)
 Dim the output to indicate that the result is no longer guaranteed to be correlated with the input cell from which it was derived.
 

Public Attributes

std::shared_ptr< TeXEngine::TeXRequest > content
 
sigc::signal< bool(DTree::iterator)> show_hide_requested
 
sigc::signal< void()> select_requested
 Emitted on a button press which is not the context-menu button, so that the owner can select this cell.
 
DTree::iterator datacell
 
Gtk::Revealer rbox
 
Gtk::Box vbox
 
Gtk::Box hbox
 
int window_width =0
 
TeXArea image
 
sigc::signal< bool(std::string)> tex_error
 
sigc::signal< bool()> signal_on_copy_as_latex
 

Protected Member Functions

virtual void on_show () override
 
void on_button_pressed (int n_press, double x, double y)
 Button handling goes through a gesture controller rather than the on_button_{press,release}_event vfuncs, which are removed in GTK4.
 
void on_button_released (int n_press, double x, double y)
 
void convert ()
 
void on_copy_as_latex () const
 

Private Member Functions

float text_size () const
 

Private Attributes

TeXEngine & engine
 
bool is_error
 
cdb::ContextMenu context_menu
 
Glib::RefPtr< cdb::ClickGesture > click_gesture
 

Constructor & Destructor Documentation

◆ TeXView()

TeXView::TeXView ( TeXEngine &  eng,
DTree::iterator  it,
int  hmargin = 25 
)

◆ ~TeXView()

TeXView::~TeXView ( )
virtual

Member Function Documentation

◆ convert()

void TeXView::convert ( )
protected

◆ dim()

void TeXView::dim ( bool  d)

Dim the output to indicate that the result is no longer guaranteed to be correlated with the input cell from which it was derived.

◆ on_button_pressed()

void TeXView::on_button_pressed ( int  n_press,
double  x,
double  y 
)
protected

Button handling goes through a gesture controller rather than the on_button_{press,release}_event vfuncs, which are removed in GTK4.

◆ on_button_released()

void TeXView::on_button_released ( int  n_press,
double  x,
double  y 
)
protected

◆ on_copy_as_latex()

void TeXView::on_copy_as_latex ( ) const
protected

◆ on_show()

void TeXView::on_show ( )
overrideprotectedvirtual

◆ set_is_error()

void TeXView::set_is_error ( bool  is_error_)

◆ text_size()

float TeXView::text_size ( ) const
private

◆ update_image()

void TeXView::update_image ( )

Update the TeX image.

Member Data Documentation

◆ click_gesture

Glib::RefPtr<cdb::ClickGesture> cadabra::TeXView::click_gesture
private

◆ content

std::shared_ptr<TeXEngine::TeXRequest> cadabra::TeXView::content

◆ context_menu

cdb::ContextMenu cadabra::TeXView::context_menu
private

◆ datacell

DTree::iterator cadabra::TeXView::datacell

◆ engine

TeXEngine& cadabra::TeXView::engine
private

◆ hbox

Gtk::Box cadabra::TeXView::hbox

◆ image

TeXArea cadabra::TeXView::image

◆ is_error

bool cadabra::TeXView::is_error
private

◆ rbox

Gtk::Revealer cadabra::TeXView::rbox

◆ select_requested

sigc::signal<void()> cadabra::TeXView::select_requested

Emitted on a button press which is not the context-menu button, so that the owner can select this cell.

Previously this was done by connecting to signal_button_press_event() and relying on the default handler having already swallowed right-clicks.

◆ show_hide_requested

sigc::signal<bool(DTree::iterator)> cadabra::TeXView::show_hide_requested

◆ signal_on_copy_as_latex

sigc::signal<bool()> cadabra::TeXView::signal_on_copy_as_latex

◆ tex_error

sigc::signal<bool(std::string)> cadabra::TeXView::tex_error

◆ vbox

Gtk::Box cadabra::TeXView::vbox

◆ window_width

int cadabra::TeXView::window_width =0

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