On Thu, 03 Oct 2013, Marty McGlensey wrote: > Good morning all, > > > > I'm running Gambas version 3.4.2. I have a form containing a datasource. The > datasource is linked to a table containing a primary index field. I've > placed datacontrols on the datasource. All controls contain appropriate > data. The problem is that the datacontrol linked to the primary index field > has a different font and background than the other datacontrols. The cursor > function is also different. This datacontrol's font is bolded; the > background is medium gray. All other datacontrol text is not bold and the > background is white and the cursor works as expected. > > > > I have three instances of this behavior, each in a different table. Each one > is linked to the primary index in that table. The datacontrol properties are > set to the defaults except for the field name. Yes the datacontrol is > enabled and visible. I've tried changing the background manually but that > has no effect. Why is this happening? Looks like it has to do with the > underlying field. I would like to have this field displayed like the others > and accept user input to be saved to the datatable. >
Yes, I don't know the details but DataControls behave differently according to the underlying field type. The thing with the primary index is that you should (or can?) not change it. The bold font is most likely an aesthetic thing. So far the reason. (You can also have a look at the source code[0].) If you can influence the DataControl's self-setup, or if it can be implemented, is something Benoit has to say. Regards, Tobi [0] http://sourceforge.net/p/gambas/code/HEAD/tree/gambas/trunk/comp/src/gb.db.form/.src/DataControl.class and the accompanying DataField.class are particularly interesting here. Both are relatively easy to comprehend for such an advanced component. ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user