Dillo v3.1.1-14-g8f67d6e0
Loading...
Searching...
No Matches
dw::fltk::ui Namespace Reference

FLTK implementation of dw::core::ui. More...

Classes

class  ComplexButton
 
class  FltkCheckButtonResource
 
class  FltkComplexButtonResource
 
class  FltkEntryResource
 
class  FltkLabelButtonResource
 
class  FltkListResource
 
class  FltkMultiLineTextResource
 
class  FltkOptionMenuResource
 
class  FltkRadioButtonResource
 
class  FltkResource
 ... More...
 
class  FltkSelectionResource
 
class  FltkSpecificResource
 
class  FltkToggleButtonResource
 

Enumerations

enum  { RELIEF_X_THICKNESS = 3 , RELIEF_Y_THICKNESS = 3 }
 

Functions

static core::ButtonState getDwButtonState ()
 
static void setButtonEvent (dw::core::EventButton *event)
 
static int kf_backspace_word (int c, Fl_Text_Editor *e)
 

Detailed Description

FLTK implementation of dw::core::ui.

Update: The complicated design results from my insufficient knowledge of C++ some years ago; since then, I've learned how to deal with "diamond inheritance", as the (ideal, not actually implemented) design in the first diagram shows. It should be possible to implement this ideal design in a straightforward way, and so get rid of templates. –SG

The design should be like this:

dot_inline_dotgraph_18.png
[legend]

where dw::fltk::ui::FltkResource provides some base funtionality for all conctrete FLTK implementations of sub-interfaces of dw::core::ui::Resource. However, this is not directly possible in C++, since the base class dw::core::ui::Resource is ambiguous for dw::fltk::ui::FltkLabelButtonResource.

To solve this, we have to remove the dependency between dw::fltk::ui::FltkResource and dw::core::ui::Resource, instead, the part of dw::core::ui::Resource, which is implemented in dw::fltk::ui::FltkResource, must be explicitly delegated from dw::fltk::ui::FltkLabelButtonResourceto dw::fltk::ui::FltkResource:

dot_inline_dotgraph_19.png
[legend]

To make this a bit simpler, we use templates:

dot_inline_dotgraph_20.png
[legend]

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
RELIEF_X_THICKNESS 
RELIEF_Y_THICKNESS 

Definition at line 394 of file fltkui.cc.

Function Documentation

◆ getDwButtonState()

static core::ButtonState dw::fltk::ui::getDwButtonState ( )
static

◆ kf_backspace_word()

static int dw::fltk::ui::kf_backspace_word ( int  c,
Fl_Text_Editor *  e 
)
static

◆ setButtonEvent()

static void dw::fltk::ui::setButtonEvent ( dw::core::EventButton event)
static