Emmanuel Stapf [ES] | 5 Oct 2006 07:43
Favicon

RE: programmatically controlled an EV_COMBO_BOX

Unless I'm missing something, you simply need to call `enable_select' on the
EV_LIST_ITEM you want to select, and `selected_item' on the EV_COMBO_BOX to
retrieve the current selected item.

The calls to `select_region' and `selected_text' applies to the displayed text
in the combo, not to the item you want to select.

Regards,
Manu

> -----Original Message-----
> From: eiffel_software@... 
> [mailto:eiffel_software@...] On Behalf Of Thomas Beale
> Sent: Wednesday, October 04, 2006 7:49 AM
> To: eiffel_software@...
> Subject: [eiffel_software] programmatically controlled an EV_COMBO_BOX
> 
> 
> I have spent quite a while messing around trying to achieve 
> something I thought would be simple. My application starts 
> up, and it knows from the last session which item was chosen 
> in a COMBO_BOX. There are two
> settings: "All" and "Leaf" (used to control a view in another 
> widget). 
> The setting is saved to a file, and read in when the tool is 
> started again. To make the Combo box go to the saved setting, 
> I do the following:
> 
>             path_filter_combo.set_strings 
> (path_control_filter_names) -- set the possible string values 
(Continue reading)

Thomas Beale | 5 Oct 2006 13:19
Picon

Re: programmatically controlled an EV_COMBO_BOX

Emmanuel Stapf [ES] wrote:
> Unless I'm missing something, you simply need to call `enable_select' on the
> EV_LIST_ITEM you want to select, and `selected_item' on the EV_COMBO_BOX to
> retrieve the current selected item.
>
> The calls to `select_region' and `selected_text' applies to the displayed text
> in the combo, not to the item you want to select.
>   
Thanks Manu,

that fixes it.

What I find counter-intuitive is:
* why I need to go to a piece of something (an EV_LIST_ITEM inside an 
EV_COMBO_BOX) to get it to display, when the notion of displaying one of 
a number of pieces is logically a function of the owning control - the 
combo box...
* secondly, "enable_select" I find a very unintuitively named function - 
"enable_x" to me says: "make doing x possible", not "do x". Does anyone 
else find this confusing? I raise this because clarity of naming and 
purpose of functions in the Vision2 system is essential for us to have 
any hope of making sense of the thousands of functions (sometimes over 
100 on a single class). Generally they are pretty well-named, but these 
"enable" ones are often not.

- thomas
> Regards,
> Manu
>
>   
(Continue reading)

Emmanuel Stapf [ES] | 10 Oct 2006 00:38
Favicon

RE: programmatically controlled an EV_COMBO_BOX

> What I find counter-intuitive is:
> * why I need to go to a piece of something (an EV_LIST_ITEM inside an 
> EV_COMBO_BOX) to get it to display, when the notion of 
> displaying one of 
> a number of pieces is logically a function of the owning 
> control - the combo box...

Because Vision2 consider this to be a property of the item. I agree there is a
fine line between what each party should be allowed to do.

> * secondly, "enable_select" I find a very unintuitively named 
> function - 

Makes sense. `select' and `deselect' might have been more intuitive. Those names
were chosen a long time ago because in Vision2 the pattern `enable/disable' is
used. We can think about better naming for future releases.

Thanks,
Manu

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
(Continue reading)

Eric Bezault | 10 Oct 2006 09:47
Gravatar

Re: programmatically controlled an EV_COMBO_BOX

Emmanuel Stapf [ES] wrote:
>>* secondly, "enable_select" I find a very unintuitively named 
>>function - 
> 
> Makes sense. `select' and `deselect' might have been more intuitive. 

Note that 'select' is a keyword.

-- 
Eric Bezault
mailto:ericb@...
http://www.gobosoft.com

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...

(Continue reading)

Emmanuel Stapf [ES] | 10 Oct 2006 16:55
Favicon

RE: programmatically controlled an EV_COMBO_BOX

> Note that 'select' is a keyword.

Indeed, that might be the reason why the enable/disable pattern was chosen.
Suggestions for a better name?

Manu

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    eiffel_software-unsubscribe@...

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

(Continue reading)

Peter Horan | 10 Oct 2006 17:08
Picon
Favicon

Re: programmatically controlled an EV_COMBO_BOX

Emmanuel Stapf [ES] wrote:
>> Note that 'select' is a keyword.
> 
> Indeed, that might be the reason why the enable/disable pattern was chosen.
> Suggestions for a better name?

mark, mark_selected? These may not gel with other enable-disable pairs though.
-- 
Peter Horan               School of Engineering and Information Technology
peter@...       Deakin University
+61-3-5227 1234 (Voice)   Geelong, Victoria 3217, AUSTRALIA
+61-3-5227 2028 (FAX)     http://www.eit.deakin.edu.au/~peter

-- The Eiffel guarantee: From specification to implementation
-- (http://www.cetus-links.org/oo_eiffel.html)

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
(Continue reading)

Thomas Beale | 10 Oct 2006 22:07
Picon

Re: programmatically controlled an EV_COMBO_BOX

Peter Horan wrote:
> Emmanuel Stapf [ES] wrote:
>   
>>> Note that 'select' is a keyword.
>>>       
>> Indeed, that might be the reason why the enable/disable pattern was chosen.
>> Suggestions for a better name?
>>     
>
> mark, mark_selected? These may not gel with other enable-disable pairs though.
>   
even 'select_item' would be better than 'enable_select' - and anyway, it 
is not beyond the realms of possibility that you do in fact want to be 
able to enable and disable select, but this is not the same as actually 
doing a 'select' in the GUI....I still think it would be more sensible 
to have select_item(i:INTEGER) in the containing EV_COMBO_BOX.

- t

--

-- 
___________________________________________________________________________________
CTO Ocean Informatics (http://www.OceanInformatics.biz)
Research Fellow, University College London (http://www.chime.ucl.ac.uk)
Chair Architectural Review Board, openEHR (http://www.openEHR.org)

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/
(Continue reading)

Picon

LACE Syntax

Dear Manu,

I recently studied in full the LACE Syntax in appendix D in Eiffel the
Language (I believe first edition) and supplemented that study with the LACE
Syntax page
http://docs.eiffel.com/eiffelstudio/tools/eiffelstudio/reference/30_compiler
/50_technology/20_lace_syntax.html

It leaves me with a few questions:

1.  Are the following system-level options only or can they also be
overridden at cluster level in a cluster's "default" and "option" clauses?

        address_expression
        syntax_warning
        inlining  and  inlining_size

2.  Are there other possible values for the "msil_generation_type" option
other than "exe"?

3.  I notice that "optimize" is still a keyword in the LACE keyword list.
Is it still in use?  If so, what does it mean?

4.  By trying different checkboxes in the Debug tab of the project
information dialog, I see how the "debug" and "disabled_debug" options work
together.  It appears (from ETL 1st Ed.) that the "debug" option was
originally intended to be available at the system level and overridable at
the cluster level.  Is that true today?  Is it the same for the
"disabled_debug" option?

(Continue reading)

Patrick Ruckstuhl [ES] | 11 Oct 2006 17:18
Favicon

Re: LACE Syntax

Hi

> I recently studied in full the LACE Syntax in appendix D in Eiffel the
> Language (I believe first edition) and supplemented that study with the LACE
> Syntax page
> http://docs.eiffel.com/eiffelstudio/tools/eiffelstudio/reference/30_compiler
> /50_technology/20_lace_syntax.html

The LACE syntax does no longer exist in EiffelStudio 5.7 and newer, so
I'll answer your questions for the new system.

> 1.  Are the following system-level options only or can they also be
> overridden at cluster level in a cluster's "default" and "option" clauses?
> 
>         address_expression
>         syntax_warning
>         inlining  and  inlining_size
Address expression, inlining and inlining size are target options (so
they apply to every cluster)
The new config system has a concept of warnings which can be controlled
on a cluster level. Syntax warning is one of the warnings.

> 2.  Are there other possible values for the "msil_generation_type" option
> other than "exe"?
dll

> 3.  I notice that "optimize" is still a keyword in the LACE keyword list.
> Is it still in use?  If so, what does it mean?
Optimize is not used at the moment

(Continue reading)

Picon

RE: Re: LACE Syntax

Thank you, Patrick and Peter!  I didn't realize LACE went away as of 5.7 --
I guess I need to update my 5.6 environment, eh?

Kind regards,
Vic Wheeler

  -----Original Message-----
  From: eiffel_software@...
[mailto:eiffel_software@...]On Behalf Of Patrick Ruckstuhl [ES]
  Sent: Wednesday, October 11, 2006 9:19 AM
  To: eiffel_software@...
  Subject: [eiffel_software] Re: LACE Syntax

  Hi

  > I recently studied in full the LACE Syntax in appendix D in Eiffel the
  > Language (I believe first edition) and supplemented that study with the
LACE
  > Syntax page
  >
http://docs.eiffel.com/eiffelstudio/tools/eiffelstudio/reference/30_compiler
  > /50_technology/20_lace_syntax.html

  The LACE syntax does no longer exist in EiffelStudio 5.7 and newer, so
  I'll answer your questions for the new system.

  > 1. Are the following system-level options only or can they also be
  > overridden at cluster level in a cluster's "default" and "option"
clauses?
  >
(Continue reading)

Peter Gummer | 11 Oct 2006 08:52
Picon

Re: LACE Syntax

Vic Wheeler wrote:
> 2.  Are there other possible values for the "msil_generation_type"
> option other than "exe"?

It can also be "dll".

But you do realise that LACE is obsolete, don't you, as of EiffelStudio 5.7?

- Peter Gummer 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    eiffel_software-unsubscribe@...

(Continue reading)

Emmanuel Stapf [ES] | 11 Oct 2006 06:34
Favicon

Re: programmatically controlled an EV_COMBO_BOX

> even 'select_item' would be better than 'enable_select' - and anyway, it
> is not beyond the realms of possibility that you do in fact want to be
> able to enable and disable select, but this is not the same as actually
> doing a 'select' in the GUI....I still think it would be more sensible
> to have select_item(i:INTEGER) in the containing EV_COMBO_BOX.

It would be in that case `select_item (i: EV_LIST_ITEM)' since all entries 
in a combo box are EV_COMBO_BOX because this is a convention we have in 
vision2.

Regards,
Manu 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...

(Continue reading)

Peter Gummer | 11 Oct 2006 09:07
Picon

Re: Re: programmatically controlled an EV_COMBO_BOX

Emmanuel Stapf wrote:
>
> It would be in that case `select_item (i: EV_LIST_ITEM)' since all entries
> in a combo box are EV_COMBO_BOX because this is a convention we have
> in vision2.

I think you meant to say that all entries in a combo box are EV_LIST_ITEM, 
yes?

It's sometimes handy, in my experience of working with combo boxes in other 
GUI frameworks, to be able to specify the index. So why not have both?

    select_index (i: INTEGER)
        require
            i >= 1
            i <= count -- assuming EV_COMBO_BOX has a 'count' query
        ensure
            selected_index = i -- assuming a 'selected_index' query

And

    select_item (i: EV_LIST_ITEM)
        require
            has (i) -- assuming EV_COMBO_BOX has a 'has' query
        ensure
            item = i -- assuming an 'item' query

These EiffelVision features would be far superior to those other frameworks 
with which I'm familiar, because these commands would be equipped with 
contracts :-) No more leafing through the documentation, swearing at its 
(Continue reading)

Karsten Heusser | 26 Oct 2006 15:30
Picon
Picon

Re: programmatically controlled an EV_COMBO_BOX

Dear Peter and Manu,

go_i_th, force_i_th and put_i_th
are extensively used as commands
in the base library.

Therefore, I would suggest to have
select_i_th (i: INTEGER) instead of
select_index (i: INTEGER)
in combo boxes.

Regards,
Karsten

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...
(Continue reading)

Emmanuel Stapf [ES] | 11 Oct 2006 18:16
Favicon

RE: Re: programmatically controlled an EV_COMBO_BOX

> I think you meant to say that all entries in a combo box are 
> EV_LIST_ITEM, yes?

Indeed.

I like your suggestions. Will think about this for the release after 5.7.

Thanks,
Manu

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:eiffel_software-digest@... 
    mailto:eiffel_software-fullfeatured@...

<*> To unsubscribe from this group, send an email to:
    eiffel_software-unsubscribe@...

(Continue reading)

Peter Horan | 6 Oct 2006 03:14
Picon
Favicon

Re: programmatically controlled an EV_COMBO_BOX

Thomas Beale wrote:

> * secondly, "enable_select" I find a very unintuitively named function - 
> "enable_x" to me says: "make doing x possible", not "do x". Does anyone 
> else find this confusing? 

That contributed to my not responding.
-- 
Peter Horan               School of Engineering and Information Technology
peter@...       Deakin University
+61-3-5227 1234 (Voice)   Geelong, Victoria 3217, AUSTRALIA
+61-3-5227 2028 (FAX)     http://www.eit.deakin.edu.au/~peter

-- The Eiffel guarantee: From specification to implementation
-- (http://www.cetus-links.org/oo_eiffel.html)

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/eiffel_software/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/eiffel_software/join
    (Yahoo! ID required)

<*> To change settings via email:
(Continue reading)


Gmane