Table field

Peter Haworth pete at lcsql.com
Sat Jun 23 12:03:19 EDT 2012


Thank you Bjornke, that's another great solution.  I guess my attempt to do
this with a repeat loop to set the background of each line to either empty
or a color was way too simplistic.

I have to say that, now I'm learning more about what can be done with
tables, I'm less and less inclined to use datagrids.

Thanks to all the recent input, I now have a table with alternating colored
rows, resizable columns, drag and drop reordering of lines, and I've added
a field at the top of my tables to hold headings and allow the columns to
be sorted by clicking on them.

Datagrid tables still have their place if you need to have an option
menu/checkbox/radio button in a column and the LC tables can't emulate a
datagrid form but for simple, straightforward display of data, the tables
seem easier to use.

Pete
lcSQL Software <http://www.lcsql.com>



On Sat, Jun 23, 2012 at 6:28 AM, Björnke von Gierke <bvg at mac.com> wrote:

> To cook yourself the perfect scrolling field, you need:
>
> A graphic:
> 32 pixels high
> at least 1 pixel wide (or more for easier handling, width doesn't matter)
> upper 16 pixels white
> lower half very light blue or very light grey
>
> Also a list type field (dontwrap= true) with:
> textHeight = 16
> fixedLineHeight = True
> margins (on the "text formatting" part of the inspector): 8,4,8,8
> set the backgroundPatter of this field to the image.
>
>
> Result:
> Perfect scrolling list of entries, where the background colors scroll
> along with the text.
>
>
> Tip: a textHeight of 16 with the default 11 textSize looks a bit cramped,
> you can adjust the hight of the lines and the hight of the graphic for
> other linesizes.
>
>
>
> On 21.06.2012, at 23:29, Peter Haworth wrote:
>
> > Thanks Bernd, that looks very nice.
> > Pete
> > lcSQL Software <http://www.lcsql.com>
> >
> >
> >
> > On Thu, Jun 21, 2012 at 2:01 PM, BNig <niggemann at uni-wh.de> wrote:
> >
> >> Hi Peter,
> >>
> >> here is my take on the alternating Lines. It uses a graphic with a
> >> fillgradient that is behind the non-opaque table field.
> >> I made a demo stack:
> >>
> >>
> berndniggemann.on-rev.com/alternatingLines/alternatingLines.livecode.zip
> >>
> >> Kind regards
> >>
> >> Bernd
> >>
> >>
> >> --
> >> View this message in context:
> >>
> http://runtime-revolution.278305.n4.nabble.com/Table-field-tp4651080p4651090.html
> >> Sent from the Revolution - User mailing list archive at Nabble.com.
> >>
> >> _______________________________________________
> >> use-livecode mailing list
> >> use-livecode at lists.runrev.com
> >> Please visit this url to subscribe, unsubscribe and manage your
> >> subscription preferences:
> >> http://lists.runrev.com/mailman/listinfo/use-livecode
> >>
> > _______________________________________________
> > use-livecode mailing list
> > use-livecode at lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
> --
>
> Use an alternative Dictionary viewer:
> http://bjoernke.com/bvgdocu/
>
> Chat with other RunRev developers:
> http://bjoernke.com/chatrev/
>
>
>
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>



More information about the use-livecode mailing list