FLTK logo

Re: [fltk.coredev] Fl_Flex method name question

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.coredev  ]
 
Previous Message ]New Message | Reply ]Next Message ]

Re: Fl_Flex method name question Bill Spitzak Oct 24, 2022  
 
Or hasSize()?

On Mon, Oct 24, 2022 at 10:30 AM Gonzalo Garramuño <ggarra13@gmail.com> wrote:


El 24/10/22 a las 14:12, 'melcher....@googlemail.com' via fltk.coredev escribió:
Is `int set_size(Fl_Widget *w) const;` correct, or should it be `int get_size(Fl_Widget *w) const;` with a 'g'. Since it's `const`, it's only returning something, and not setting anything. --

It should probably be neither.  A better name for it would be:

bool check_size(Fl_Widget* w) const

as it does not return the value of the widget size but checks whether there's a value set for it.

--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/31831a38-157e-90be-1d69-60a4f4fb4178%40gmail.com.

--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/CAL-8oAiTBDPm_XFKq6y9oeCL0Hf6dmtFRTa%3D8BC6dFH5k6p40Q%40mail.gmail.com.
Direct Link to Message ]
 
     
Previous Message ]New Message | Reply ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.