1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363 |
- class IUP_FLAT_TABS
- inherit
- IUP_CANVAS
- redefine
- execute_flat_button,
- execute_flat_motion,
- execute_flat_leavewindow,
- execute_tabchange,
- execute_tabchangepos,
- execute_tabclose,
- execute_rightclick,
- execute_extrabutton
- end
- IUP_WIDGET_CLIENTSIZE
- IUP_WIDGET_CLIENTOFFSET
- IUP_WIDGET_NAME
- IUP_WIDGET_FLAT_TEXT
- IUP_WIDGET_FLOATING
- IUP_WIDGET_CHILDSIZEALL
- create {ANY}
- flat_tabs_empty,
- flat_tabs
- feature {ANY}
- flat_tabs_empty
-
- local
- p, a_flat_tabs: POINTER
- do
- a_flat_tabs := int_flat_tabs_empty (p)
- set_widget(a_flat_tabs)
- end
-
- flat_tabs (col: ARRAY[IUP_WIDGET])
-
- local
- i: INTEGER; arg: ARRAY[POINTER]; s: IUP_WIDGET; a_flat_tabs: POINTER
- do
- i := col.count
- create arg.make_filled(default_pointer, 1, i + 1)
- i := 0
-
- across
- col as ic
- loop
- i := i + 1
- s := ic.item
- arg.put(s.widget, i)
- end
- a_flat_tabs := int_flat_tabs (get_pointer(arg.to_c))
- set_widget(a_flat_tabs)
- end
-
- set_rgb_fore_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
- do
- iup_open.set_attribute(Current, "FORECOLOR", rgb_to_string(red, green, blue))
- end
- get_rgb_fore_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "FORECOLOR")
- end
- set_rgb_highlight_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
-
-
- do
- iup_open.set_attribute(Current, "HIGHCOLOR", rgb_to_string(red, green, blue))
- end
- get_rgb_highlight_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "HIGHCOLOR")
- end
-
- set_child_offset (horizontal, vertical: INTEGER)
-
-
-
-
-
- require
- horizontal >= 0
- vertical >= 0
- local
- offset: STRING
- do
- offset := horizontal.out
- offset.append_string("x")
- offset.append_string(vertical.out)
- iup_open.set_attribute(Current, "CHILDOFFSET", offset)
- end
- get_child_offset: TUPLE[INTEGER, INTEGER]
-
- local
- offset: STRING
- do
- offset := iup_open.get_attribute(Current, "CHILDOFFSET")
- Result := components_of_size(offset)
- end
-
- get_count: INTEGER
-
- do
- Result := get_child_count
- end
- set_fixed_width (state: BOOLEAN)
-
- do
- iup_open.set_attribute(Current, "FIXEDWIDTH", boolean_to_yesno(state))
- end
- is_fixed_width: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "FIXEDWIDTH")
- Result := yesno_to_boolean(str)
- end
- set_show_close (state: BOOLEAN)
-
-
-
- do
- iup_open.set_attribute(Current, "SHOWCLOSE", boolean_to_yesno(state))
- end
- is_show_close: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "SHOWCLOSE")
- Result := yesno_to_boolean(str)
- end
- set_show_lines (state: BOOLEAN)
-
-
- do
- iup_open.set_attribute(Current, "SHOWLINES", boolean_to_yesno(state))
- end
- is_show_lines: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "SHOWLINES")
- Result := yesno_to_boolean(str)
- end
- set_tab_change_on_check (state: BOOLEAN)
-
-
- do
- iup_open.set_attribute(Current, "TABCHANGEONCHECK", boolean_to_yesno(state))
- end
- is_tab_change_on_check: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "TABCHANGEONCHECK")
- Result := yesno_to_boolean(str)
- end
- set_tabs_padding (horizontal, vertical: INTEGER)
-
-
-
- require
- horizontal >= 0
- vertical >= 0
- local
- padding: STRING
- do
- padding := horizontal.out
- padding.append_string("x")
- padding.append_string(vertical.out)
- iup_open.set_attribute(Current, "TABSPADDING", padding)
- end
- get_tabs_padding: TUPLE[INTEGER, INTEGER]
-
- local
- padding: STRING
- do
- padding := iup_open.get_attribute(Current, "TABSPADDING")
- Result := components_of_size(padding)
- end
- set_tabs_rgb_fore_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
-
- do
- iup_open.set_attribute(Current, "TABSFORECOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_fore_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "TABSFORECOLOR")
- end
- set_tabs_rgb_background_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
-
- do
- iup_open.set_attribute(Current, "TABSBACKCOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_background_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "TABSBACKCOLOR")
- end
- set_tabs_rgb_highlight_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
-
- do
- iup_open.set_attribute(Current, "TABSHIGHCOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_highlight_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "TABSHIGHCOLOR")
- end
- set_tabs_font (font: STRING)
-
-
- do
- iup_open.set_attribute(Current, "TABSFONT", font)
- end
- get_tabs_font: STRING
-
- do
- Result := iup_open.get_attribute(Current, "TABSFONT")
- end
- set_tabs_font_style (fontstyle: STRING)
-
- do
- iup_open.set_attribute(Current, "TABSFONTSTYLE", fontstyle)
- end
- get_tabs_font_style: STRING
-
- do
- Result := iup_open.get_attribute(Current, "TABSFONTSTYLE")
- end
- set_tabs_font_size (fontsize: INTEGER)
-
- do
- iup_open.set_attribute(Current, "TABSFONTSIZE", fontsize.out)
- end
- get_tabs_font_size: INTEGER
-
- local
- size: STRING
- do
- size := iup_open.get_attribute(Current, "TABSFONTSIZE")
- Result := size.to_integer
- end
- set_tabs_text_alignment (value: STRING)
-
-
- require
- is_valid: is_valid_horizontal_alignment(value)
- do
- iup_open.set_attribute(Current, "TABSTEXTALIGNMENT", value)
- end
- get_tabs_text_alignment: STRING
- do
- Result := iup_open.get_attribute(Current, "TABSTEXTALIGNMENT")
- end
- set_tabs_text_wrap (state: BOOLEAN)
-
-
-
-
-
-
- do
- iup_open.set_attribute(Current, "TABSTEXTWRAP", boolean_to_yesno(state))
- end
- set_tabs_text_ellipsis (state: BOOLEAN)
-
-
-
- do
- iup_open.set_attribute(Current, "TABSTEXTELLIPSIS", boolean_to_yesno(state))
- end
- set_tabs_text_orientation (value: REAL_64)
-
-
- do
- iup_open.set_attribute(Current, "TABSTEXTORIENTATION", value.out)
- end
- set_tab_type_top
-
-
-
- do
- iup_open.set_attribute(Current, "TABTYPE", "TOP")
- end
- set_tab_type_bottom
-
-
-
- do
- iup_open.set_attribute(Current, "TABTYPE", "BOTTOM")
- end
- set_tab_type_left
-
-
-
- do
- iup_open.set_attribute(Current, "TABTYPE", "LEFT")
- end
- set_tab_type_right
-
-
-
- do
- iup_open.set_attribute(Current, "TABTYPE", "RIGHT")
- end
- set_tab_orientation_horizontal
-
- do
- iup_open.set_attribute(Current, "TABORIENTATION", "HORIZONTAL")
- end
- set_tab_orientation_vertical
-
- do
- iup_open.set_attribute(Current, "TABORIENTATION", "VERTICAL")
- end
- set_tabs_rgb_line_color (red: INTEGER; green: INTEGER; blue: INTEGER)
-
- do
- iup_open.set_attribute(Current, "TABSLINECOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_line_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "TABSLINECOLOR")
- end
- set_tabs_image_position (value: STRING)
-
-
- require
- is_valid: is_valid_position(value)
- do
- iup_open.set_attribute(Current, "TABSIMAGEPOSITION", value)
- end
- get_tabs_image_position: STRING
- do
- Result := iup_open.get_attribute(Current, "TABSIMAGEPOSITION")
- end
- set_tabs_image_spacing (value: INTEGER)
-
- require
- positive: value >= 0
- do
- iup_open.set_attribute(Current, "TABSIMAGESPACING", value.out)
- end
- get_tabs_image_spacing: STRING
- do
- Result := iup_open.get_attribute(Current, "TABSIMAGESPACING")
- end
- set_tabs_alignment (horizontal, vertical: STRING)
-
-
-
- require
- is_valid_tabs_alignment(horizontal, vertical)
- local
- str: STRING
- do
- create str.make_from_string(horizontal)
- str.append_string(":")
- str.append_string(vertical)
-
- iup_open.set_attribute(Current, "TABSALIGNMENT", str)
- end
- get_tabs_alignment: TUPLE[INTEGER, INTEGER]
-
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "TABSALIGNMENT")
- Result := components_of(str, ':')
- end
-
- set_tab_n_image (imagename: STRING; n: INTEGER)
-
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABIMAGE", n, imagename)
- end
- get_tab_n_image (n: INTEGER): STRING
-
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABIMAGE", n)
- end
- set_tab_n_image_highlight (imagename: STRING; n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABIMAGEHIGHTLIGHT", n, imagename)
- end
- get_tab_n_image_highlight (n: INTEGER): STRING
-
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABIMAGEHIGHTLIGHT", n)
- end
- set_tab_n_image_inactive (imagename: STRING; n: INTEGER)
-
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABIMAGEINACTIVE", n, imagename)
- end
- get_tab_n_image_inactive (n: INTEGER): STRING
-
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABIMAGEINACTIVE", n)
- end
- set_tab_n_visible (state: BOOLEAN; n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "TABVISIBLE", n, boolean_to_yesno(state))
- end
- is_tab_n_visible (n: INTEGER): BOOLEAN
-
- require
- n >= 0
- local
- str: STRING
- do
- str := iup_open.get_attribute_id(Current, "TABVISIBLE", n)
- Result := yesno_to_boolean(str)
- end
- set_tab_n_title (title: STRING; n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "TABTITLE", n, title)
- end
- get_tab_n_title (n: INTEGER): STRING
-
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABTITLE", n)
- end
- set_tab_n_active (state: BOOLEAN; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABACTIVE", n, boolean_to_yesno(state))
- end
- is_tab_n_active (n: INTEGER): BOOLEAN
-
- require
- n >= 0
- local
- str: STRING
- do
- str := iup_open.get_attribute_id(Current, "TABACTIVE", n)
- Result := yesno_to_boolean(str)
- end
- set_tab_n_rgb_fore_color (red, green, blue, n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABFORECOLOR", n, rgb_to_string(red, green, blue))
- end
- get_tab_n_rgb_fore_color (n: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- n >= 0
- do
- Result := iup_open.get_rgb_id(Current, "TABFORECOLOR", n)
- end
- set_tab_n_rgb_background_color (red, green, blue, n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABBACKCOLOR", n, rgb_to_string(red, green, blue))
- end
- get_tab_n_rgb_background_color (n: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- n >= 0
- do
- Result := iup_open.get_rgb_id(Current, "TABBACKCOLOR", n)
- end
- set_tab_n_rgb_highlight_color (red, green, blue, n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABHIGHCOLOR", n, rgb_to_string(red, green, blue))
- end
- get_tab_n_rgb_highlight_color (n: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- n >= 0
- do
- Result := iup_open.get_rgb_id(Current, "TABHIGHCOLOR", n)
- end
- set_tab_n_font (font: STRING; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABFONT", n, font)
- end
- get_tab_n_font (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABFONT", n)
- end
- set_tab_n_font_style (fontstyle: STRING; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABFONTSTYLE", n, fontstyle)
- end
- get_tab_n_font_style (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABSFONTSTYLE", n)
- end
- set_tab_n_font_size (fontsize, n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABFONTSIZE", n, fontsize.out)
- end
- get_tab_n_font_size (n: INTEGER): INTEGER
- require
- n >= 0
- local
- size: STRING
- do
- size := iup_open.get_attribute_id(Current, "TABFONTSIZE", n)
- Result := size.to_integer
- end
- set_tab_n_tip (tip: STRING; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id(Current, "TABTIP", n, tip)
- end
- get_tab_n_tip (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABTIP", n)
- end
-
- set_tab_close_image (imagename: STRING)
-
-
-
- do
- iup_open.set_attribute(Current, "CLOSEIMAGE", imagename)
- end
- get_tab_close_image: STRING
- do
- Result := iup_open.get_attribute(Current, "TABIMAGE")
- end
- set_tab_close_image_press (imagename: STRING)
-
-
- do
- iup_open.set_attribute(Current, "CLOSEIMAGEPRESS", imagename)
- end
- get_tab_close_image_press: STRING
- do
- Result := iup_open.get_attribute(Current, "CLOSEIMAGEPRESS")
- end
- set_tab_close_image_highlight (imagename: STRING)
-
- do
- iup_open.set_attribute(Current, "CLOSEIMAGEHIGHLIGHT", imagename)
- end
- get_tab_close_image_highlight: STRING
- do
- Result := iup_open.get_attribute(Current, "CLOSEIMAGEHIGHLIGHT")
- end
- set_tab_close_image_inactive (imagename: STRING)
-
-
-
- do
- iup_open.set_attribute(Current, "CLOSEIMAGEINACTIVE", imagename)
- end
- get_tab_close_image_inactive: STRING
- do
- Result := iup_open.get_attribute(Current, "CLOSEIMAGEINACTIVE")
- end
- set_tab_rgb_close_press_color (red, green, blue: INTEGER)
-
-
- do
- iup_open.set_attribute(Current, "CLOSEPRESSCOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_close_press_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "CLOSEPRESSCOLOR")
- end
- set_tab_rgb_close_highlight_color (red, green, blue: INTEGER)
-
-
- do
- iup_open.set_attribute(Current, "CLOSEHIGHCOLOR", rgb_to_string(red, green, blue))
- end
- get_tabs_rgb_close_highlight_color: TUPLE[INTEGER, INTEGER, INTEGER]
- do
- Result := iup_open.get_rgb(Current, "CLOSEHIGHCOLOR")
- end
-
- set_extra_buttons (buttons: INTEGER)
-
-
-
-
-
-
-
-
- require
- buttons >= 0
- do
- iup_open.set_attribute(Current, "EXTRABUTTONS", buttons.out)
- end
- get_extra_buttons: INTEGER
- do
- Result := iup_open.get_attribute(Current, "EXTRABUTTONS").to_integer
- end
- set_title_at_extra_button (title: STRING; button: INTEGER)
-
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRATITLE", button, title)
- end
- get_title_at_extra_button (button: INTEGER): STRING
- require
- button >= 0
- do
- Result := iup_open.get_attribute_id(Current, "EXTRATITLE", button)
- end
- set_extra_button_active (button: INTEGER; state: BOOLEAN)
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRAACTIVE", button, boolean_to_yesno(state))
- end
- is_extra_button_active (button: INTEGER): BOOLEAN
- require
- button >= 0
- local
- str: STRING
- do
- str := iup_open.get_attribute_id(Current, "EXTRAACTIVE", button)
- Result := yesno_to_boolean(str)
- end
- set_extra_button_rgb_fore_color (red, green, blue, button: INTEGER)
-
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRAFORECOLOR", button, rgb_to_string(red, green, blue))
- end
- get_extra_button_rgb_fore_color (button: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- button >= 0
- do
- Result := iup_open.get_rgb_id(Current, "EXTRAFORECOLOR", button)
- end
- set_extra_button_rgb_press_color (red, green, blue, button: INTEGER)
-
-
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRAPRESSCOLOR", button, rgb_to_string(red, green, blue))
- end
- get_extra_button_rgb_press_color (button: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- button >= 0
- do
- Result := iup_open.get_rgb_id(Current, "EXTRAPRESSCOLOR", button)
- end
- set_extra_button_rgb_highlight_color (red, green, blue, button: INTEGER)
-
-
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRAHIGHCOLOR", button, rgb_to_string(red, green, blue))
- end
- get_extra_button_rgb_highlight_color (button: INTEGER): TUPLE[INTEGER, INTEGER, INTEGER]
- require
- button >= 0
- do
- Result := iup_open.get_rgb_id(Current, "EXTRAHIGHCOLOR", button)
- end
- set_extra_button_font (font: STRING; button: INTEGER)
-
- require
- button >= 0
- do
- iup_open.set_attribute_id(Current, "EXTRAFONT", button, font)
- end
- get_extra_button_font (button: INTEGER): STRING
- require
- button >= 0
- do
- Result := iup_open.get_attribute_id(Current, "EXTRAFONT", button)
- end
- set_extra_button_n_image (imagename: STRING; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "TABIMAGE", n, imagename)
- end
- get_extra_button_n_image (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABIMAGE", n)
- end
- set_extra_button_n_image_press (imagename: STRING; n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "TABIMAGEPRESS", n, imagename)
- end
- get_extra_button_n_image_press (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "TABIMAGEPRESS", n)
- end
- set_extra_button_n_image_highlight (imagename: STRING; n: INTEGER)
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "EXTRAIMAGEHIGHLIGHT", n, imagename)
- end
- get_extra_button_n_image_highlight (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "EXTRAIMAGEHIGHLIGHT", n)
- end
- set_extra_button_n_image_inactive (imagename: STRING; n: INTEGER)
-
-
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "EXTRAIMAGEINACTIVE", n, imagename)
- end
- get_extra_button_n_image_inactive (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "EXTRAIMAGEINACTIVE", n)
- end
- set_extra_button_n_tip (tip: STRING; n: INTEGER)
-
- require
- n >= 0
- do
- iup_open.set_attribute_id (Current, "EXTRATIP", n, tip)
- end
- get_extra_button_n_tip (n: INTEGER): STRING
- require
- n >= 0
- do
- Result := iup_open.get_attribute_id(Current, "EXTRATIP", n)
- end
-
- set_extra_expand_button (state: BOOLEAN)
-
-
-
-
- do
- iup_open.set_attribute(Current, "EXPANDBUTTON", boolean_to_yesno(state))
- end
- has_extra_expand_button: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "EXPANDBUTTON")
- Result := yesno_to_boolean(str)
- end
- get_expand_button_position: INTEGER
-
- do
- Result := iup_open.get_attribute(Current, "EXPANDBUTTONPOS").to_integer
- end
- set_expand_button_state (state: BOOLEAN)
-
-
- do
- iup_open.set_attribute(Current, "EXPANDBUTTONSTATE", boolean_to_yesno(state))
- end
- get_expand_button_state: BOOLEAN
- local
- str: STRING
- do
- str := iup_open.get_attribute(Current, "EXPANDBUTTONSTATE")
- Result := yesno_to_boolean(str)
- end
-
- set_value (name: STRING)
-
-
-
- do
- iup_open.set_attribute(Current, "VALUE", name)
- end
-
- get_value: STRING
-
- do
- Result := iup_open.get_attribute(Current, "VALUE")
- end
- set_value_widget (wgt: IUP_WIDGET)
-
-
-
- do
- iup_open.set_attribute_widget(Current, "VALUE_HANDLE", wgt)
- end
- get_value_widget: IUP_WIDGET
-
- do
- Result := iup_open.get_attribute_widget(Current, "VALUE_HANDLE")
- end
- set_value_position (value: INTEGER)
-
-
-
- require
- value >= 0
- do
- iup_open.set_attribute(Current, "VALUEPOS", value.out)
- end
- get_value_position: INTEGER
-
- do
- Result := iup_open.get_attribute(Current, "VALUEPOS").to_integer
- end
-
- convert_xy_to_pos (x, y: INTEGER): INTEGER
-
- do
- Result := iup_open.iup_convert_xy_to_pos (Current, x, y)
- end
-
- set_cb_flat_button (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER, INTEGER, INTEGER, STRING], STRING])
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- local
- operation: INTEGER
- do
- cb_flat_button := act
- if cb_flat_button /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "FLAT_BUTTON_CB", "NONEEDED", operation)
- end
- set_cb_flat_motion (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER, STRING], STRING])
-
-
-
-
-
-
- local
- operation: INTEGER
- do
- cb_flat_motion := act
- if cb_flat_motion /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "FALT_MOTION_CB", "NONEEDED", operation)
- end
- set_cb_flat_leave_window (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS], STRING])
-
- local
- operation: INTEGER
- do
- cb_flat_leavewindow := act
- if cb_leavewindow /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "FLAT_LEAVEWINDOW_CB", "NONEEDED", operation)
- end
-
- set_cb_tab_change (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, IUP_WIDGET, IUP_WIDGET], STRING])
-
- local
- operation: INTEGER
- do
- cb_tabchange := act
- if cb_tabchange /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "TABCHANGE_CB", "NONEEDED", operation)
- end
- set_cb_tab_change_position (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER], STRING])
-
-
- local
- operation: INTEGER
- do
- cb_tabchangepos := act
- if cb_tabchangepos /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "TABCHANGEPOS_CB", "NONEEDED", operation)
- end
- set_cb_tab_close (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER], STRING])
-
-
- local
- operation: INTEGER
- do
- cb_tabclose := act
- if cb_tabclose /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "TABCLOSE_CB", "NONEEDED", operation)
- end
- set_cb_right_click (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER], STRING])
-
-
- local
- operation: INTEGER
- do
- cb_rightclick := act
- if cb_rightclick /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "RIGHTCLICK_CB", "NONEEDED", operation)
- end
- set_cb_extra_button (act: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER], STRING])
-
-
-
-
-
-
-
-
- local
- operation: INTEGER
- do
- cb_extrabutton := act
- if cb_extrabutton /= Void then
- operation := 1
- else
- operation := 0
- end
-
- iup_open.set_callback (Current, "EXTRABUTTON_CB", "NONEEDED", operation)
- end
-
- is_valid_position (type: STRING): BOOLEAN
- do
- if type.is_equal("TOP") or
- type.is_equal("BOTTOM") or
- type.is_equal("LEFT") or
- type.is_equal("RIGHT") then
- Result := True
- else
- Result := False
- end
- end
- is_valid_tabs_alignment (horizontal, vertical: STRING): BOOLEAN
- local
- h, v: BOOLEAN
- do
- if horizontal.is_equal("ALEFT") or
- horizontal.is_equal("ACENTER") or
- horizontal.is_equal("ARIGHT") then
- h := True
- else
- h := False
- end
- if vertical.is_equal("ATOP") or
- vertical.is_equal("ACENTER") or
- vertical.is_equal("ABOTTOM") then
- v := True
- else
- v := False
- end
- if h and v then
- Result := True
- else
- Result := False
- end
- end
-
- feature {IUP}
-
-
- execute_flat_button (btn, pressed, x, y: INTEGER; status: STRING): STRING
- do
- if attached cb_flat_button as int_cb then
- Result := int_cb.item([Current, btn, pressed, x, y, status])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_flat_motion (x, y: INTEGER; status: STRING): STRING
- do
- if attached cb_flat_motion as int_cb then
- Result := int_cb.item([Current, x, y, status])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_flat_leavewindow: STRING
- do
- if attached cb_flat_leavewindow as int_cb then
- Result := int_cb.item([Current])
- else
- Result := "IUP_DEFAULT"
- end
- end
-
- execute_tabchange (new_tab, old_tab: IUP_WIDGET): STRING
- do
- if attached cb_tabchange as int_cb then
- Result := int_cb.item([Current, new_tab, old_tab])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_tabchangepos (new_pos, old_pos: INTEGER): STRING
- do
- if attached cb_tabchangepos as int_cb then
- Result := int_cb.item([Current, new_pos, old_pos])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_tabclose (pos: INTEGER): STRING
- do
- if attached cb_tabclose as int_cb then
- Result := int_cb.item([Current, pos])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_rightclick (pos: INTEGER): STRING
- do
- if attached cb_rightclick as int_cb then
- Result := int_cb.item([Current, pos])
- else
- Result := "IUP_DEFAULT"
- end
- end
- execute_extrabutton (button, pressed: INTEGER): STRING
- do
- if attached cb_extrabutton as int_cb then
- Result := int_cb.item([Current, button, pressed])
- else
- Result := "IUP_DEFAULT"
- end
- end
- feature {NONE}
-
- cb_flat_button: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER, INTEGER, INTEGER, STRING], STRING]
- cb_flat_motion: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER, STRING], STRING]
- cb_flat_leavewindow: detachable FUNCTION[TUPLE[IUP_FLAT_TABS], STRING]
- cb_tabchange: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, IUP_WIDGET, IUP_WIDGET], STRING]
- cb_tabchangepos: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER], STRING]
- cb_tabclose: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER], STRING]
- cb_rightclick: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER], STRING]
- cb_extrabutton: detachable FUNCTION[TUPLE[IUP_FLAT_TABS, INTEGER, INTEGER], STRING]
-
-
- int_flat_tabs_empty (arguments: POINTER): POINTER
- external
- "C inline use %"eiffel-iup.h%""
- alias
- "return IupFlatTabs ($arguments);"
- end
-
- int_flat_tabs (arguments: POINTER): POINTER
- external
- "C inline use %"eiffel-iup.h%""
- alias
- "return IupFlatTabsv ($arguments);"
- end
- end
|