52 #ifndef __PCL_ComboBox_h
53 #define __PCL_ComboBox_h
57 #ifndef __PCL_BUILDING_PIXINSIGHT_APPLICATION
121 int FindItem(
const String& text,
int fromIdx = 0,
bool exactMatch =
false,
bool caseSensitive =
false )
const;
146 InsertItem( NumberOfItems(), text, icon );
169 InsertItem( index++, *i );
185 InsertItems( NumberOfItems(), i, j );
206 InsertItems( index, c.Begin(), c.End() );
221 InsertItems( NumberOfItems(), c );
251 SetItemText( index,
String() );
295 EnableEdit( !disable );
335 EnableAutoCompletion( !disable );
350 int w, dum; GetIconSize( w, dum );
return w;
358 int dum, h; GetIconSize( dum, h );
return h;
374 SetIconSize( size, size );
381 GetIconSize( width, height ); width = PhysicalPixelsToLogical( width ); height = PhysicalPixelsToLogical( height );
388 int width, dum; GetIconSize( width, dum );
return PhysicalPixelsToLogical( width );
395 int dum, height; GetIconSize( dum, height );
return PhysicalPixelsToLogical( height );
402 SetIconSize( LogicalPixelsToPhysical( width ), LogicalPixelsToPhysical( height ) );
409 size = LogicalPixelsToPhysical( size );
410 SetIconSize( size, size );
548 EventHandlers() =
default;
549 EventHandlers(
const EventHandlers& ) =
default;
550 EventHandlers& operator =(
const EventHandlers& ) =
default;
555 friend class ComboBoxEventDispatcher;
Client-side interface to a PixInsight Bitmap object.
Client-side interface to a PixInsight ComboBox control.
int NumberOfItems() const
void EnableAutoCompletion(bool=true)
int MaxVisibleItemCount() const
void SetIconSize(int width, int height)
void DisableAutoCompletion(bool disable=true)
void ClearItemIcon(int index)
int ScaledIconWidth() const
void SetScaledIconSize(int width, int height)
void InsertItems(int index, FI i, FI j)
ComboBox(Control &parent=Control::Null())
void EnableEdit(bool=true)
void InsertItem(int index, const String &text, const Bitmap &icon=Bitmap::Null())
void GetIconSize(int &width, int &height) const
bool IsEditEnabled() const
void RemoveItem(int index)
void DisableEdit(bool disable=true)
void AddItem(const String &text, const Bitmap &icon=Bitmap::Null())
void SetScaledIconSize(int size)
void SetMaxVisibleItemCount(int)
void InsertItems(int index, const C &c)
int FindItem(const String &text, int fromIdx=0, bool exactMatch=false, bool caseSensitive=false) const
void SetItemIcon(int index, const Bitmap &)
void SetEditText(const String &)
void SetIconSize(int size)
void SetItemText(int index, const String &)
void AddItems(const C &c)
Bitmap ItemIcon(int index) const
void SetMinItemCharWidth(int)
bool IsAutoCompletionEnabled() const
String ItemText(int index) const
void AddItems(FI i, FI j)
void GetScaledIconSize(int &width, int &height) const
int ScaledIconHeight() const
void ClearItemText(int index)
void SetCurrentItem(int index)
int MinItemCharWidth() const
Client-side interface to a PixInsight Control object.
void OnItemHighlighted(item_event_handler handler, Control &receiver)
void(Control::*)(ComboBox &sender, int itemIndex) item_event_handler
void OnItemSelected(item_event_handler handler, Control &receiver)
void(Control::*)(ComboBox &sender) edit_event_handler
void OnEditTextUpdated(edit_event_handler handler, Control &receiver)