[Gambas-user] make Label background from Database field

Doriano Blengino doriano.blengino at ...1909...
Sun Oct 18 14:00:12 CEST 2009


Kad Mann ha scritto:
> On Sun, 2009-10-18 at 10:47 +0200, Doriano Blengino wrote:
>   
>> Kad Mann ha scritto:
>>     
>>> On Sun, 2009-10-18 at 09:08 +0200, Doriano Blengino wrote:
>>>   
>>>       
>>>> Kad Mann ha scritto:
>>>>     
>>>>         
>>>>> On Sat, 2009-10-17 at 22:46 +0300, Vassilis K wrote:
>>>>>
>>>>>   
>>>>>       
>>>>>           
>>>>>> Dimitri I don't understand
>>>>>>     
>>>>>>         
>>>>>>             
>>>>> Why don't you take a look at the database example in Gambas?
>>>>>
>>>>> After creating the test table, if you type in an SQL command and click
>>>>> the run button, you will see a gridview with a myriad colours that can
>>>>> be changed based on the data. Surely something like that has to be
>>>>> easier than trying to work out how to manage a hundred labels on a
>>>>> screen, and surely it will offer you much better and easier control of
>>>>> future UI changes, and surely it will offer a more pleasing and
>>>>> intuitive presentation to your user.
>>>>>   
>>>>>       
>>>>>           
>>>> "Surely something like that has to be easier" and "surely much better 
>>>> and easier control".
>>>> Yes and no
>>>>     
>>>>         
>>> I didn't ask you.
>>>   
>>>       
>> True, and neither Vassilis asked you something... you can't understand 
>> him, but I can understand you. In one of your last mail you noticed that 
>> data controls don't have all the properties as other textboxes, such 
>> alignment and so on. Be prepared for other surprises. Everybody would 
>> love to have controls with lots of properties in order to do everything 
>> you want, but this is impossible (can you believe it? Once you have put 
>> 100 properties in a control, you will find someone asking for the #101). 
>>     
>
> Of course, the point is, I didn't ask for the features. Did I? I asked
> is the limitation by design, are there plans to change it, and is there
> a workaround.
>   
You are very precise... so I will do too. I didn't say *you* asked for 
features (did I?). Nevertheless you was talking about features...
> Besides, do you feel it is unreasonable for someone to want "a box used
> to show the contents of a Field or edit it", a data-bound control
> intended to save programming time, to have similar functionality to a
> TextBox?
>   
No.
>   
>> Real programmers prefer to do things their way, with few versatile 
>> mechanisms.
>>     
>
> So, who do you believe might not be a real programmer?
>   
Are you expecting I say "you"? No. I don't know who you are, and even if 
I don't agree with you, I can not say you are not a real programmer.
But BEWARE! In some future, perhaps I will do! Even at night! :-)

>>  The more a component gets complicated, the less people 
>> understand it; just now, many problems arise from the fact that people 
>> don't read documentation, and even when they do, they don't notice some 
>> important feature; and often that feature is not exactly you need.
>>     
>
> So, you feel that if a DataControl was given similar functionality to a
> TextBox, you might not understand it?
>   
No, again it was a general talking. But are you sure you fully 
understand Columnview?
I noticed that, for example, checkboxes lack the Autosize property. It 
would make sense that every control like labels, textboxes, checkboxes 
and data controls had a set of common properties. But for this kind of 
things gambas relies on either QT or GTK, and sometimes you find limits 
in them. Be prepared...
I tried (and actually succeded) to write a file manager in gambas. But I 
faced all kind of problems, and I had to rewrite DirTreeView and 
DirFileView (or whatever is named). Do it it you too, then you'll better 
understand what I am trying to say. The more a component has 
functionalities, the more you will find they are not what you want.

Hey guy, keep it cool.
Regards,

-- 
Doriano Blengino

"Listen twice before you speak.
This is why we have two ears, but only one mouth."





More information about the User mailing list