comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » not seeing the added values in widget_table?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
not seeing the added values in widget_table? [message #60743] Thu, 05 June 2008 16:11
yoyoteng is currently offline  yoyoteng
Messages: 3
Registered: July 2007
Junior Member
One question for those of you who have been using widget_tables,

The table that I'm creating needs to have a fixed (screen) size.
Initially, there is nothing to show on the widget_table, but later on,
I will need to show array[100] in the table.

When creating the table, I have added Y_SCROLL_SIZE=3, /SCROLL to fix
the size and enable the scroll. "During" the program, I have used the
"Set_Value" and "Get_value" to confirm that the data is correctly
passed into the table, however, I cannot scroll down to view the rest
of the data.

What is missing here?
ANY comments is welcomed!

Below is a sample code to illustrate my problem.
;====================================================

; Event-handler routine for 'Quit' button
PRO table_widget_example22_quit_event, ev
WIDGET_CONTROL, ev.TOP, /DESTROY
END

; Widget creation routine.
PRO table_widget_example22
;;code was originally one of IDL's examples:
table_widget_example2.pro ;;
; Create some structure data.
d0={planet:'Mercury', orbit:0.387, radius:2439, moons:0, orbi1t:
1.524, r1adius:3397, m1oons:2}
d1={planet:'Venus', orbit:0.723, radius:6052, moons:0, orbi1t:1.524,
r1adius:3397, m1oons:2}
d2={planet:'Earth', orbit:1.0, radius:6378, moons:1, orbi1t:1.524,
r1adius:3397, m1oons:2}
d3={planet:'Mars', orbit:1.524, radius:3397, moons:2, orbi1t:1.524,
r1adius:3397, m1oons:2}

; Combine structure data into a vector of structures.
data = [d0, d1 ]

; Create base widget, two tables (column- and row-major,
; respectively), and 'Quit' button.
base = WIDGET_BASE(/COLUMN)

table1 = WIDGET_TABLE(base, VALUE=data, /ROW_MAJOR, $
ROW_LABELS='', COLUMN_LABELS='', $
/RESIZEABLE_COLUMNS, /SCROLL, Y_SCROLL_SIZE=3)

b_quit = WIDGET_BUTTON(base, VALUE='Quit', $
EVENT_PRO='table_widget_example22_quit_event')
; Realize the widgets.
WIDGET_CONTROL, base, /REALIZE

data = [d0, d1 , d2, d3,d0, d1, d2, d3,d0, d1, d2, d3,d0, d1, d2,
d3]
WIDGET_CONTROL, table1, set_value=data

WIDGET_CONTROL, table1, get_value=a
help,a
; Call XMANAGER to manage the widgets.
XMANAGER, 'table_widget_example22', base

END
;====================================================
[Message index]
 
Read Message
Previous Topic: Re: IOstream in IDL?
Next Topic: Re: Problem with brainless Windows IDL7

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 11:26:40 PDT 2025

Total time taken to generate the page: 1.51222 seconds