robertj@unreal.uucp (Young Rob Jellinghaus) (03/20/91)
I'm trying to use the List Manager to fill a window with a simple, one- column list. I've got it mostly working, except for one thing: When I create the window and the new list, I pass 0's for the cellSize. This is supposed to create a reasonable default. And so it does; it makes a cellSize that is the width of the starting window. But then if I resize the window, the cellSize doesn't change! And what's more, if I stick a really long item in a cell, the horizontal scrollbar doesn't work properly to scroll the whole window and show me the whole long item. Any suggestions as to what I might be missing? The only sample List Manager code I have is for a modal dialog.... -- Rob Jellinghaus | "Next time you see a lie being spread or Autodesk, Inc. | a bad decision being made out of sheer robertj@Autodesk.COM | ignorance, pause, and think of hypertext." {decwrl,uunet}!autodesk!robertj | -- K. Eric Drexler, _Engines of Creation_
cs483106@umbc5.umbc.edu (cs483106) (03/21/91)
In article <3424@autodesk.COM> you write: >I'm trying to use the List Manager to fill a window with a simple, one- >column list. I've got it mostly working, except for one thing: >When I create the window and the new list, I pass 0's for the cellSize. >This is supposed to create a reasonable default. And so it does; it >makes a cellSize that is the width of the starting window. >But then if I resize the window, the cellSize doesn't change! And what's >more, if I stick a really long item in a cell, the horizontal scrollbar >doesn't work properly to scroll the whole window and show me the whole >long item. >Any suggestions as to what I might be missing? The only sample List >Manager code I have is for a modal dialog.... >Rob Jellinghaus Note that the following is ONLY MY understanding of the list manager. It too could be very flawed, however I have managed to implement some programs using the list manager. OK, your problem is that you have some simple misconceptions about the List Manager's capabilities. your first problem(with the re-sizing window) is that the List Manager doesn't do changing cell sizes. It's designed to display simple 1 or 2 dimensional lists, with a fixed cell size. It's really intended(it seems) to be used from within modal dialogs. If you want the cell size to change, you're gonna have to do it yourself. Try modifying the cell size in the ListHandle, then re-drawing the list on a window re- size. Might work(I haven't ever done it though). Your other problem(horizontal scroll bar) is the same sort of thing. The scroll bars in the list manager are designed to scroll CELLS, not within cells. If you want to scroll horizontally within a cell, you might try writing your own LDEF, and having a seperate horizontal scroll bar (same position as the standard one, but you are in control) that tells the LDEF which part of the cell to be displaying. Kind of a hack any way you look at it. "Pope" Q.E.D Michael Kohne mikek@isis.ngs.noaa.gov