Re: need advise on grid like control...

2004-08-27 Thread Hershel Fisch
It's a reference to a possible library of duplicatable functions that 
would doc individual fields into columns and rows and size them 
properly based on border sizes for each row or column. It should also 
set line hight and font types and sizes. It should probably be done as 
an array or set of arrays and stored using a pull-parser in MTML. :-) 
There should also be global attributes for column formatting. All this 
should be like a spreadsheet layout processor. It should even handle 
the naming conventions for each field with names like r1c1, r2c1, 
r1c2, etc... It should even handle math attributes for running 
calculations from one field, ranges of fields into another field or 
fields. In other words it should be a stack that acts like a storable 
spreadsheet. Having object control over individual field objects could 
lead to extremely powerful acting spreadsheets.

Now there's a bit of work for the person that has nothing better to do.
Got that.
Thanks
Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-26 Thread Mark Brownell
On Thursday, August 26, 2004, at 12:06 PM, Hershel Fisch wrote:
What is the docking handler ?
Hershel

Don't hurry on my account. I don't need it. I would just work on the 
docking handler if I had nothing better to do. (I wish)

Mark
It's a reference to a possible library of duplicatable functions that 
would doc individual fields into columns and rows and size them 
properly based on border sizes for each row or column. It should also 
set line hight and font types and sizes. It should probably be done as 
an array or set of arrays and stored using a pull-parser in MTML. :-) 
There should also be global attributes for column formatting. All this 
should be like a spreadsheet layout processor. It should even handle 
the naming conventions for each field with names like r1c1, r2c1, r1c2, 
etc... It should even handle math attributes for running calculations 
from one field, ranges of fields into another field or fields. In other 
words it should be a stack that acts like a storable spreadsheet. 
Having object control over individual field objects could lead to 
extremely powerful acting spreadsheets.

Now there's a bit of work for the person that has nothing better to do.
Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-26 Thread Hershel Fisch
What is the docking handler ?
Hershel
On Tuesday, August 24, 2004, at 07:29 PM, Mark Brownell wrote:
On Tuesday, August 24, 2004, at 04:25 PM, Mark Talluto wrote:
Nothing too magical under the hood.  It is a bunch of fields aligned 
next to each other.  I will see what it takes to rip it out of my 
program and post it.  I expect to be back into that program next >> week.
Don't hurry on my account. I don't need it. I would just work on the 
docking handler if I had nothing better to do. (I wish)

Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-25 Thread Mark Waddingham
On Tue, 24 Aug 2004, Andre Garzia wrote:

> Hi Folks,
>
> I am building a little project manager here. I would like to be able to
> show a calendar like control so that the user could grasp the big
> picture of his project, like iCal and MS Project do. I am finding the
> ...

Just to add my two-pence to the mix...

You may also want to have a look at the 'lists' in the Revolution Online
Learning Center (e.g. Learning Center -> Video Tutorials -> All) - this is
effectively a custom table view that uses individual fields for each cell.
It's basically just a group that responds to custom properties and a
handful of messages - it is also entirely devoid of instructions/comments
at the moment, but figuring out how things work is part of the fun, isn't
it? ;o)

It could be optimized somewhat, and made more 'complete' - but it
exemplifies one way of doing things.

Anyway, if it looks useful, I'll happily rip it out of revOnline, clean it
up and make a more user-friendly example stack out of it as soon as I get
the chance.

Best wishes,

Mark.

-
  Mark Waddingham ~ 36degrees @ runrev.com ~ http://www.runrev.com/
   Runtime Revolution ~ User-Centric Development Tools


___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


RE: need advise on grid like control...

2004-08-24 Thread MisterX
[EMAIL PROTECTED] wrote:

> -- UM, what a minute. If RR gave me all the tools to do it, yeah, I
> would rool my own. But after so many years, I have yet seen anyone
> really make a true data grid that general enough as a tool for all to
> customize. I think 100 pluse votes says much.

Well, it's been available in my DiscreteBrowser since last year!
It's as easy as
set the tabstops of fld myfieldname to FindTabStops(myfieldname)

And the stack source is still opened! Unfortunately due to a serie of
issues with GM, html-based images, unfinished features, stack corruption
I havent released an upgrade. Im in the process of retesting a newer
browser.

Here it is a self configuring self sizing tabstop finder
I created it to translate the HTML Tables in the discrete browser
to a RR grid depending on the formattedwidth of the text in these
columns.

http://monsieurx.com/modules.php?name=Downloads&d_op=getit&lid=44

I've commented the function for the occasion.
Look in the comments for what is configurable.

  -- tool using this should check that maxfwt is ok
  -- in case the field had no tab characters
  -- example
  put FindTabStops(myfieldname) into maxfwt
  if maxfwt is not empty and item 1 of maxfwt is not 0
  then set the tabStops of fld fldname to maxfwt

function FindTabStops fldname
  local maxfw=0,txtsize
  local fldwidthdiv2, sourcelines
  local ht
  local maxtabs=2, maxtabline=1
  local ftxtsize

  put the textheight of fld fldname into txtsize
  put the width of fld fldname div 2 into fldwidthdiv2
  put the number of lines in fld fldname into sourcelines

  put fld fldname into ht

  set the itemdelimiter to tab
  -- find the largest formattedwidths for each column and line
   repeat with y = 1 to sourcelines
get the number of items in line y of ht
if it > maxtabs then
  put y into maxtabline
  put it into maxtabs
end if
  end repeat

  -- you can customize the default width of your columns here.
  -- note the local variable "defaultwidth" created problems with
  -- RR script compiler before 2.5

  local defaltwidth=100, lcount

  -- optional auto configuration for defaultwidth
  --put (the width of fld fldname) div maxtabs-1 into defaltwidth
  put the fontsize of fld fldname into ftxtsize
  if ftxtsize is empty then put 12 into ftxtsize
  repeat with x = 1 to maxtabs
put defaltwidth into item x of maxfw
  end repeat
  -- now, for each line
  repeat with y = 1 to sourcelines
--set cursor to busy -- slows things down on large scripts
put the number of items in line y of ht into lcount
if lcount < 2 then next repeat
-- for each item, find the best or custom fit
repeat with l = 1 to lcount
  get the formattedwidth of item l of line y of fld fldname
  if it < defaltwidth then get defaltwidth
  if it > item l of maxfw then
put it into item l of maxfw
  end if
end repeat
  end repeat

  -- if a column is suposed to be center or right adjusted
  -- you can put a loop per line to pad with spaces here.

  local maxfwt,maxitems,lastit
  put the number of items in maxfw into maxitems
  put 0 into lastit
  repeat with x = 1 to maxitems
   -- note the different settings you can have in this loop
   -- this is the where you define if a column is fixed or not.
   get item x of maxfw
if x = 1 then
  put it+10 & comma after maxfwt -- here we set a fixed width if we know
the column
  --put it & comma after maxfwt -- a small offset can help
  else if x = maxitems then
  put it + 1000 after maxfwt -- last item has a larger width so it is
not visible
else
  get it + 12 + lastit -- normal width
  put it & comma after maxfwt
end if
put it into lastit
  end repeat
  -- delete last char of maxfwt
  return maxfwt
end FindTabStops

-- FindTabstops will always return a list of items equal to the number
   of tab delimited columns as found in the field in question.
-- Some columns may not be correctly set - Im aware of this issue and
   despite tweaking this function for each app, it remains a mistery why.
   I suspect a formattedWidth problem - an explanation is truely welcome!
--
So instead of wasting votes on RR non-issues, please vote for my bugs and
if you can explain the reason why Form...Wid.. is not always correct, im
interested! ;)

The other solution and surely it's been explored in the list is to create
vertical column fields which you can directly align left right center which
is even better.

The last solution is to use the format function - but it doesn't respect
alignment either.

If you check most of my tool including WinN2O, pieControl, etc... they all
use the same 2 fields, autotabstops, and autosort columns.

Why customize when you can automate?

cheers
Xavier

--
http://MonsieurX.com
A virtual garage for revolutionary tools
RR Plugins, applications, links and tips
--

___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/

Re: need advise on grid like control...

2004-08-24 Thread Mark Talluto
I just posted the pertinent code to my cell routine at:
http://www.canelasoftware.com/pub/rev/datagrid.rev.sit
I also update RevNet once version 2.0 is done.
--
Best regards,
Mark Talluto
http://www.canelasoftware.com
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Sarah Reichelt
So, anyone here got an advise? I am planning to make a grid like this:
* first column is a status column is a status one, it will show a 
image (red ball or green ball depending on the status)
* second column is a string with the project task title (yes, variable 
width...)
* from the third and beyond, I would like to put the days and color 
them depending on the context.

Firstly, download Rinaldi's TabRuler plugin - it makes working with 
tabStops enormously easier: go to  and 
click on the “Revolution Stuff” button in the column on the left. In 
the plugins section of his Revolution page, you will see “TabRuler.” 
Click on the disk icon to download the zip file.

Secondly, I don't quite see what is causing the problems. You aren't 
trying to do anything too weird and I use tables for this sort of thing 
a lot. Set your tabStops and make sure you have vertical grid turned on 
- this stops columns with lots of text overlapping the next column, 
although if you don't want to show the grid, you can make it the same 
color as the field.

You can either use htmlText to format the lines (image & color), or put 
a space in the first column of each line and use the imageSource 
property to show your status images instead of the space. With the 
colors of the later columns, I would write a handler that takes the row 
number, column number & color and sets the relevant characters to the 
specified color.

Lastly, have a look at Chipp's altFldHeader which allows you to use a 
group of header buttons to resize and sort columns in the associated 
field: 


Cheers,
Sarah
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Mark Brownell
On Tuesday, August 24, 2004, at 04:25 PM, Mark Talluto wrote:
Nothing too magical under the hood.  It is a bunch of fields aligned 
next to each other.  I will see what it takes to rip it out of my 
program and post it.  I expect to be back into that program next week.
Don't hurry on my account. I don't need it. I would just work on the 
docking handler if I had nothing better to do. (I wish)

Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Mark Talluto
On Aug 24, 2004, at 4:12 PM, Mark Brownell wrote:
On Tuesday, August 24, 2004, at 03:41 PM, Mark Talluto wrote:
I have an app called Lesson Plan Generator.  Take a look at the demo. 
 If the cell/grid structure looks useful to you, I will make it 
available to anyone who wants it.  I am working a a major upgrade to 
the program that will allow row resizing as only column resizing is 
available.  You can get the demo at:  


--
Best regards,
Mark Talluto
That's a nice example of a grid. The cell/grid part would be nice to 
have handy.

Nothing too magical under the hood.  It is a bunch of fields aligned 
next to each other.  I will see what it takes to rip it out of my 
program and post it.  I expect to be back into that program next week.

--
Best regards,
Mark Talluto
http://www.canelasoftware.com
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Mark Brownell
On Tuesday, August 24, 2004, at 03:41 PM, Mark Talluto wrote:
I have an app called Lesson Plan Generator.  Take a look at the demo.  
If the cell/grid structure looks useful to you, I will make it 
available to anyone who wants it.  I am working a a major upgrade to 
the program that will allow row resizing as only column resizing is 
available.  You can get the demo at:  


--
Best regards,
Mark Talluto
That's a nice example of a grid. The cell/grid part would be nice to 
have handy.

Thanks,
Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Mark Talluto
On Aug 24, 2004, at 11:25 AM, Mark Brownell wrote:
There's good news and bad news. If you use an individual field object 
for each table cell and you write a docking handler that allows for 
loc and rect changes then you have a very powerful library that does 
what you need. This could be the beginning of reinventing the 
spreadsheet. Perhaps someone has already created such a stack?

Mark
I have an app called Lesson Plan Generator.  Take a look at the demo.  
If the cell/grid structure looks useful to you, I will make it 
available to anyone who wants it.  I am working a a major upgrade to 
the program that will allow row resizing as only column resizing is 
available.  You can get the demo at:  


--
Best regards,
Mark Talluto
http://www.canelasoftware.com
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Chipp Walters
Hi Andre,
I'm not exactly sure what you're after, but it appears from your 
description fairly easy to do.

Just use htmlText for each line. For instance:
set the htmlText of line 1 of fld "timeline" to \
	Task One		

You'll need to get the secondColumn formattedTextWidth and set your 
tabstops accordingly. I've done this many times for my projects.

btw, 	 is the html for tab
-Chipp
Andre Garzia wrote:
So, anyone here got an advise? I am planning to make a grid like this:
* first column is a status column is a status one, it will show a image 
(red ball or green ball depending on the status)
* second column is a string with the project task title (yes, variable 
width...)
* from the third and beyond, I would like to put the days and color them 
depending on the context.
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Trevor DeVore
On Aug 24, 2004, at 11:16 AM, Richard Gaskin wrote:
But I believe the formattedWidth function works on chunks, no?  If so, 
it should simplify the arithmetic for determining tabStops.
It does indeed work on chunks.  I just learned this the other day while 
working on a data grid viewer and it changed my life.  One day I will 
learn to pay more attention when reading the docs.

--
Trevor DeVore
Blue Mango Multimedia
[EMAIL PROTECTED]
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Mark Brownell
On Tuesday, August 24, 2004, at 11:06 AM, Andre Garzia wrote:
So, anyone here got an advise? I am planning to make a grid like this:
* first column is a status column is a status one, it will show a 
image (red ball or green ball depending on the status)
* second column is a string with the project task title (yes, variable 
width...)
* from the third and beyond, I would like to put the days and color 
them depending on the context.

why is it so hard?
There's good news and bad news. If you use an individual field object 
for each table cell and you write a docking handler that allows for loc 
and rect changes then you have a very powerful library that does what 
you need. This could be the beginning of reinventing the spreadsheet. 
Perhaps someone has already created such a stack?

Mark
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Troy Rollins
On Aug 24, 2004, at 2:06 PM, Andre Garzia wrote:
So, anyone here got an advise? I am planning to make a grid like this:
* first column is a status column is a status one, it will show a  
image (red ball or green ball depending on the status)
* second column is a string with the project task title (yes, variable  
width...)
* from the third and beyond, I would like to put the days and color  
them depending on the context.

why is it so hard?
This is the sort of "data grid" that I have been saying is lacking in  
Rev currently - though you have some additional and specific needs.  
There is a popular feature request in -   


Which I see you have already committed 5 votes to. The current total  
for that feature is at 131 votes, which is pretty high among requested  
features.

I've taken some rough stabs at creating them in Transcript, but I don't  
have the patience or the Transcript finesse with fields to get them to  
work correctly.
--
Troy
RPSystems, Ltd.
http://www.rpsystems.net

___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution


Re: need advise on grid like control...

2004-08-24 Thread Richard Gaskin
Andre Garzia wrote:
Hi Folks,
I am building a little project manager here. I would like to be able to 
show a calendar like control so that the user could grasp the big 
picture of his project, like iCal and MS Project do. I am finding the 
field control very bad for it, the tabStops thing is horrible to design 
grids, I must calculate the biggest string, make arcane math to find how 
much pixels it will take and set the tabstops so that they do not 
overlap and so on... 
The multi-column grid option built into the engine is designed for 
database-style views, not multi-line cell grids, so yes, attempting to 
make it work like a different type of grid will be some work.

But I believe the formattedWidth function works on chunks, no?  If so, 
it should simplify the arithmetic for determining tabStops.

> I thought about using the htmlText property and
render a HTML table, but hey, my fields are not rendering the  
tag... 
Not yet, but you can vote for it:

So, anyone here got an advise? I am planning to make a grid like this:
* first column is a status column is a status one, it will show a image 
(red ball or green ball depending on the status)
* second column is a string with the project task title (yes, variable 
width...)
* from the third and beyond, I would like to put the days and color them 
depending on the context.
If these fields only display a single line you may find the built-in 
multi-column option to be just fine.

If you need multiple lines then creating a separate field for each cell 
may be the way to go.

--
 Richard Gaskin
 Fourth World Media Corporation
 ___
 [EMAIL PROTECTED]   http://www.FourthWorld.com
___
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution