[REBOL] Image-Lab Function Implementation

2001-03-03 Thread Robbo1Mark

Jeff,

Image-Lab function in it's current incarnation does not have the appropriate 
behaviour in all instances.

For example consider the effects block [rotate 90]

Whilst the effect works perfectly, you will see that there is a problem with 
the face/size, the  face/size/x and face/size/y values should be swapped here 
so
that the full image appears rotated on it's side.

Is this easily fixed within the current implementation design of passing 
'effects as parameters in a block? (maybe the 'effects arguments should also 
have a word! option.)

for example

image/lab/preview/bmp %ukiah.jpg %ukiah.bmp 'invert

whilst this is a trivial change, what about the proper behaviour of certain 
effects?

This is only the first anomaly I've discovered, without doing a full test of 
all effects options we don't know if there might be more.

Maybe Implementing effects as refinements may offer the fine grained control 
needed to ensure proper behaviour.

I hope not, because I like your design of effects being a block! (or word!), 
much smaller and cleaner.

Your thoughts please,

Mark Dickson
-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: mimetypes, loopback, object serialistion tool: minidisk

2001-03-03 Thread . -

That's great!  Thank you.  Now I not only have this as a tool, I have a new 
example of how to write a new protocol for rebol (which I've been having 
trouble figuring out)


   Cal Dixon
   --

From: Volker Nitsch [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: [REBOL] mimetypes, loopback, object serialistion tool: minidisk
Date: Sat, 03 Mar 2001 05:06:57 GMT

REBOL [

   title: "mimetypes, loopback, object serialistion tool: minidisk"

   purpose: {

installs a scheme ram:// which actually works as a ramdisk.
this disk can be saved completely to a single file and restored later.
is meant to be minimal, do deleteing and such by access to 'ram/files
.
output is enbase-64 compressed.
only read/write, no open/append/close (simpler)(advanced version
available).
}
   usage: {

  [do %minidisk.r] read/write ram://filename stuff
  [ram/save %your-file.r]
  [do %yourfile.r];disk back :)

  append your own startup in 'save behind 'ram/install .
}
   name: "minidisk"
   file: %minidisk.r
   author: "volker"
]

ram: context [

   header: none
   save: func [file'] [
   system/words/save/header file' compose [
   ram: do decompress debase (enbase compress mold make self 
[header:
none])
   ram/install
   ] third load mold make header [file: file' date: now]
   ]
   install: does [header: system/script/header net-utils/net-install
'RAM self 9900]
   init: func [port spec] [
   net-utils/url-parser/parse-url port spec
   port/locals: to file! skip spec length? to url! "RAM://"
   ]
   open: func [port] [
   port/state/flags: port/state/flags or
system/standard/port-flags/direct
   ]
   read: func [port data /local len] [
   either port/locals [
   insert data debase select files port/locals
   port/locals: none
   length? data
   ] [0]
   ]
   write: func [port data /local found] [
   either found: find files port/locals [
   change next found enbase copy data
   ] [
   repend files [port/locals enbase data]
   ]
   length? data
   ]
   close: func [port] []

   files: copy []
]

do example: [
   ram/install
   ? ram
   write ram://write.txt "hello"
   print read ram://write.txt
   ? ram
   ram/save %minidisk1.r
   print read %minidisk1.r
   do %minidisk1.r
;  ? ram
]






--
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the
subject, without the quotes.


_
Get your FREE download of MSN Explorer at http://explorer.msn.com

-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] CPAN for REBOL

2001-03-03 Thread Robbo1Mark

I would like to enquire if anybody has the time to setup and run
effectively a Comprehensive Archive Network simlir to PERL CPAN
for REBOL scripts.

The Script Library at REBOL.com is only updated infrequently
and REBOL.org appears all but dead.

A properly managed resource system for REBOL scripts and examples
is invaluable for REBOL's credibility as a language. Lots of great script
examples are posted on this list, but is anybody making a coherent and
useful resource with them?

If anybody want's to discuss a CPAN for REBOL please raise your voice
here!

PS I've also thought of a cute name that might please a certain gentleman
at REBOL TEchnologies Inc.

Here's the name, it's an acronym, of course!

CARLS: Comprehensive Archive REBOL Language Scripts

Anybody any comments?

Mark Dickson
-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: binary problem

2001-03-03 Thread Nenad Rakocevic


Hi Will,

Will Arp wrote:
 
  a: read/binary %callmov.r
 == #{
 23212F7573722F6C6F63616C2F62696E2F7265626F6C2F7265626F6C202D6373
 0A5245424F4C205B5D0A0A613A206C6F61642025767262696E320A633A20...
  same? a read/binary %callmov.r
 == false
 
 
 Hello 8)
 Well I was expecting a true result..
 Can please someone help ?

Try with 'equal? instead of 'same? :
 equal? a read/binary %callmov.r
== true

'same? will return 'true only if the two arguments refer (or point) to the
same memory space.

Basically, 'same? applied on immutable values should work as you expected.

For example with an integer! (immutable):
 a: 5
== 5
 b: a
== 5
 same? a b
== true
 c: 5
== 5
 same? a c
== true ; true !
 equal? a c
== true

but, with a string! (mutable):
 a: "foo"
== "foo"
 b: a
== "foo"
 same? a b
== true
 c: "foo"
== "foo"
 same? a c
== false; false !
 equal? a c
== true

 Is append a good way to join two binaries ?

Sure, it's a good way. You can also use 'join (should be a little bit faster).

HTH,

DocKimbel.
-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: REBOL Zen / idioms

2001-03-03 Thread Chris

#03-Mar-01# Message from *[EMAIL PROTECTED]*:
Hi [EMAIL PROTECTED],




  There's a certain zen to REBOL and it takes time to
  understand-- something that I am always learning.  

  With REBOL it usually comes down to taking a function,
  writing it, then rewriting it a few more times, carving out
  the fat while expanding the capability.  As a general rule
  most REBOL functions that are written can be reworked to
  accomplish more, to provide more use in the same amount of
  space or less.  Code in the eye of the fly and seek to know
  the true path of the REBOL way!  :-)

I sense the start of a new book - Zen and the art of REBOL
programming ;)

Chris

-- 
New sig in the works
Explorer 2260, Designer and Coder
http://www.starforge.co.uk
-- 
Violence is the last refuge of the incompetent.
-- Salvor Hardin

-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] BUG: parse-xml exposes words 'parent and 'paroot to global context

2001-03-03 Thread Christian Ensel

Hello list,

I just noticed that 'parse-xml exposes the words 'parent and 'paroot to the
global context.

I'm not sure if this has already been addressed by someone - however, I
consider this to be a bug, therefore I cc'd this mail to [EMAIL PROTECTED]

What do you think?

Regards,

Christian Ensel

-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Spreadsheet

2001-03-03 Thread Andrew Martin

Has anyone thought of making a spreadsheet in Rebol/View or Rebol/Link?

I'd really like to combine the best parts of Star Office Spreadsheet,
Microsoft Office Excel and Lotus Improv, and merge them together with a
generous helping of Rebol Script.

Andrew Martin
ICQ: 26227169 http://members.nbci.com/AndrewMartin/
--


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] newbie parsing question

2001-03-03 Thread John Sequeira

I've been wrestling unsuccessfully with the parsing dialect on the following
simple(?) problem.

I've got an IMG SRC="" tag,  and I'd like to parse the filename in the SRC
attribute.
The format of the filename is : /some-path/AAA0s0.jpg or
/some-path/AAA0s00.jpg   where A is a character [A-Z], and 0 represents
a digit.  I want to grab the one or two digits following the 's'.

In perl,  this would be something like:
$html =~ s/s([0-9]+)\.jpg/$1/

I'm having a traumatic experience mapping this to REBOL.  Any suggestions?



-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: Spreadsheet

2001-03-03 Thread Volker Nitsch



 Ursprngliche Nachricht 

Am 03.03.01, 22:17:47, schrieb "Andrew Martin" [EMAIL PROTECTED] zum 
Thema [REBOL] Spreadsheet:


 Has anyone thought of making a spreadsheet in Rebol/View or 
Rebol/Link?

 I'd really like to combine the best parts of Star Office Spreadsheet,
 Microsoft Office Excel and Lotus Improv, and merge them together with 
a
 generous helping of Rebol Script.

 Andrew Martin
 ICQ: 26227169 http://members.nbci.com/AndrewMartin/
 --

like this? (well, more a joke :)

[REBOL [title: file: %rebsheet2.r date: 6-Nov-2000/22:12:57+1:00 
autor: 'volker]
formulas: none
do rebsheet: [
file: %rebsheet2.r
as-always: 640x480
list-size: 600x380
label-size: min 640x15 list-size / 5
if not formulas [formulas: array/initial [25 5] ""
formulas/1: copy/deep [
{/do[save-me] {remove "/" = autosave (lots of!)}}
"$123" "1.5 * sheet/1/2"
{(pick pick sheet y + 0 x - 2) + (pick pick sheet y + 0 x 
- 1)}
"reduce[y x]"
]
]
sheet: copy/deep formulas
clear-sheet: does [foreach y sheet [forall y [change y 0]]]
save-me: does [
save/header file compose [formulas: (reduce [formulas])
do rebsheet: (reduce [rebsheet])]
compose [title: file: (file) date: (now) autor: 'volker]
]
set-text: func [face string] [face/text: string face/line-list: 
none 
 show face]
ed-x: ed-y: 1
myst: stylize [
sheet-label: text label-size with [y: x: none action: [
poke formulas/:ed-y ed-x copy edit/text
set-text edit copy formulas/:y/:x
ed-y: y ed-x: x show sheet-list
]]
]
view layout [size as-always
styles myst
edit: area min list-size 640x1 * 1x4 * 1x15 formulas/1/1
sheet-list: list list-size 30.30.30 [
across sheet-label sheet-label sheet-label sheet-label 
sheet-label
]
supply [
y: face/y: count x: face/x: index
either all [ed-x = x ed-y = y] [face/color: 0.0.255] 
[face/color: 30.30.30]
if all [1 = count 1 = index] [clear-sheet]
face/text: either count  length? formulas ["-"] [
if error? try [res: do formulas/:y/:x] [res: "???"]
poke sheet/:y x :res
mold :res
]
]
]
]
]
 --
 To unsubscribe from this list, please send an email to
 [EMAIL PROTECTED] with "unsubscribe" in the
 subject, without the quotes.



-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: newbie parsing question

2001-03-03 Thread Volker Nitsch

 a: {/some-path/AAA0s12.jpg}
== "/some-path/AAA0s12.jpg"
 jpg: head reverse ".jpg"
== "gpj."
 parse head reverse a [thru jpg copy b to "s" to end]
== true
 b: head reverse b
== "12"

rebol-parse has no backtracking like perl, sadly.
Comming from left is difficult in this case IMO.

something like
parse tail a [reverse thru .jpg copy b to s to end]
would be nice for such cases..

Volker

 Ursprngliche Nachricht 

Am 03.03.01, 19:39:42, schrieb "John Sequeira" [EMAIL PROTECTED] zum 
Thema [REBOL] newbie parsing question:


 I've been wrestling unsuccessfully with the parsing dialect on the 
following
 simple(?) problem.

 I've got an IMG SRC="" tag,  and I'd like to parse the filename in the 
SRC
 attribute.
 The format of the filename is : /some-path/AAA0s0.jpg or
 /some-path/AAA0s00.jpg   where A is a character [A-Z], and 0 
represents
 a digit.  I want to grab the one or two digits following the 's'.

 In perl,  this would be something like:
   $html =~ s/s([0-9]+)\.jpg/$1/

 I'm having a traumatic experience mapping this to REBOL.  Any 
suggestions?



 --
 To unsubscribe from this list, please send an email to
 [EMAIL PROTECTED] with "unsubscribe" in the
 subject, without the quotes.



-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: Spreadsheet

2001-03-03 Thread Brett Handley

The thought occurred to me. I actually did come across a situation where we
wanted to provide spreadsheet functionality but in a very constrained
manner. The reason being that the users were already using spreadsheets and
were very nervous about causing errors. So they wanted a custom program
instead, but they needed flexibility in how to define a calculation.

We never did that app, because we were going to get a "better bang for buck"
by doing other things first.

Anyways my thoughts about doing this with Rebol:
1) Need to build a grid based entry interface style. Once done, very useful
for other Rebol applications.
2) Need to code a graph sorting algorithm that gets as input the
dependencies between cell calculations.
3) Need to provide all the little user-interface niceties that people expect
from spreadsheet applications.
4) Aim to keep as much power of Rebol as possible accessible to user entered
parts of the spreadsheet.

I think (1) is the most reusable for other applications. (2) is an
interesting problem to solve.
(3) may actually be the most amount of work in the project - users expect a
lot!
but (4) is a good justification for a Rebol powered spreadsheet - Rebol
programming can be made visual...

Brett.


- Original Message -
From: "Andrew Martin" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, March 04, 2001 8:17 AM
Subject: [REBOL] Spreadsheet


 Has anyone thought of making a spreadsheet in Rebol/View or Rebol/Link?

 I'd really like to combine the best parts of Star Office Spreadsheet,
 Microsoft Office Excel and Lotus Improv, and merge them together with a
 generous helping of Rebol Script.

 Andrew Martin
 ICQ: 26227169 http://members.nbci.com/AndrewMartin/
 --


 --
 To unsubscribe from this list, please send an email to
 [EMAIL PROTECTED] with "unsubscribe" in the
 subject, without the quotes.


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: Spreadsheet

2001-03-03 Thread Robbo1Mark

Well do it then!!!

Who or what is stoppin  you?

It would be great if you could achieve something
outwith REBOL?

Mark Dickson




-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: newbie parsing question

2001-03-03 Thread Brett Handley

REBOL [
 Author: "Brett Handley"
 Title: "Parser for special files."
 Comment: "Example of parsing for John Sequeira"
]

ctx-special-file-parser: context [

 desired-number: none ; Will be set by the parser.

 a-char: charset [#"A" - #"Z" #"a" - #"z"] ; Parse rule to match characters.

 a-digit: charset [#"0" - #"9"] ; Parse rule to match digits.

 ; Parse rule to match the filename structure.
 ; Will set the field desired-number
 file-name-structure: [
  (desired-number: none)
  some a-char
  some a-digit
  #"s"
  copy desired-number some a-digit
  to end
 ]

 set 'print-special-file-number func [
  full-file-path [file!]
 ][
  either parse second split-path full-file-path file-name-structure [
   print desired-number
  ][print "parse failed"]
 ]

]

; Examples
print-special-file-number %/some-path/AAA0s0.jpg
print-special-file-number %/some-path/Absdfpkj349874s12.jpg
print-special-file-number %/some-path/As0.jpg

- Original Message -
From: "John Sequeira" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, March 04, 2001 5:39 AM
Subject: [REBOL] newbie parsing question


 I've been wrestling unsuccessfully with the parsing dialect on the
following
 simple(?) problem.

 I've got an IMG SRC="" tag,  and I'd like to parse the filename in the
SRC
 attribute.
 The format of the filename is : /some-path/AAA0s0.jpg or
 /some-path/AAA0s00.jpg   where A is a character [A-Z], and 0
represents
 a digit.  I want to grab the one or two digits following the 's'.

 In perl,  this would be something like:
 $html =~ s/s([0-9]+)\.jpg/$1/

 I'm having a traumatic experience mapping this to REBOL.  Any suggestions?



 --
 To unsubscribe from this list, please send an email to
 [EMAIL PROTECTED] with "unsubscribe" in the
 subject, without the quotes.


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] re REBOL Zen / idioms

2001-03-03 Thread David Vydra

Jeff,

In his book, Refactoring : Improving the Design of
Existing Code 
http://www.bookpool.com/.x/t7itfr3lmm/sm/0201485672 ,
Martin Fowler help programmers tame their java code. I
now consider it the most important book for learning
the Java language.

Your example is excellent and I hope that we will see
more in the future. I have certainly learned alot
about REBOL by refactoring my code many times. Next
time I suspect there is a better way to do something,
I will ask this list.

Regards,

David


--- [EMAIL PROTECTED] wrote:
 
 
 
   There's a certain zen to REBOL and it takes time
 to
   understand-- something that I am always learning. 
 
 
   REBOL has a lot of what might seem like idioms,
 which really
   are ways to do things that make life a lot easier.
  They
   stem from the craftsmanship in REBOL, the rather
 lengthy
   effort that went into its design, implementation
 and polish.
   Many problems you face in programming have a
 nicely crafted
   solution sitting inside this little binary
 interpreter, just
   waiting for you to discover it when you need it.
 
   The code that comes from REBOL should demonstrate
 that Zen
   because we all are lucky in that we can pick
 Carl's brains
   over the challenges we encounter.  Also, we're
 lucky because
   we get to write REBOL code as an occupation, so we
 get to
   find all those little crafted edges inside. I've
 always
   hoped to pass on what little I have learned of the
 Zen of
   REBOL to any who would walk in that path.
 
   Here is an example of some REBOL Zen style idioms.
 
   
 
   Consider a block of similar objects:
 
   block:  [make object! [name: "foo" phone:
 #222- ... ] ... ]
 
   Now you're writing a function and you have this
 block and it
   is really long with many of the same kinds of
 objects, but
   you need to see if there is an object which has
 the name
   field set to "Waldo" and you need to see if the
 waldo
   object's phone field is set to none, If you don't
 find this
   object you want to do somehing.  If you do find
 waldo and
   waldo has a phone you want to call waldo,
 otherwise you want
   to complain that he doesn't have a phone. 
 
   Some people might code it like this:
 
   find-waldo: func [block [block!] /local found
 waldo no-fone?][
   found: false
   foreach obj block [
   if obj/name = "waldo" [
   waldo: obj
   found: true
   no-fone?: not none? obj/phone
   ]
   ]
   if not found [wheres-waldo?]
   either no-fone?
 [waldo-has-no-phone][call-waldo waldo/phone]
   ]
 
   That's a fair approach, similar to how you might
 tackle the
   problem in basic, maybe. But with REBOL you can
 get much
   more done in place.  Most things return meaningful
 values so
   the left side of most functions represent an
 excellent
   place to dock another useful function, save space,
 save
   steps, and preserve the utility of results.
 
   How about this:
 
   find-waldo: func [block [block!] /local result][
  if not result: foreach obj block [
  if obj/name = "waldo" [break/return any
 [obj/phone yes]]
  ][wheres-waldo?]
  either issue? result [call-waldo
 result][waldo-has-no-phone]
   ]
 
   Okay, so we have less local variables, the code is
 smaller
   and therefore is more efficient usually (and in
 this case
   definitely). The first example trudged through the
 whole
   block before deciding the outcome, where above we
   BREAK/return as soon as we find waldo.  The
 FOREACH will
   return the last evaluation, so if FOREACH makes it
 through
   the whole block with out ever finding waldo it
 will return a
   NONE from the last evalutation of the IF
 statement.  We use
   the result of FOREACH to immediately determine if
 we found
   waldo.  Now if result is not a NONE, it will be
 either an
   issue!, waldo's phone number (#222-111-), or a
 TRUE
   value (yes). The TRUE is arbitrary since we just
 have to
   return a non false / non none from BREAK/return
 and we only
   check if we have an issue which means it must be
 Waldo's
   phone number.
 
   Programmers will have different styles, but the
 language
   also has a style of its own.
 
   With REBOL it usually comes down to taking a
 function,
   writing it, then rewriting it a few more times,
 carving out
   the fat while expanding the capability.  As a
 general rule
   most REBOL functions that are written can be
 reworked to
   accomplish more, to provide more use in the same
 amount of
   space or less.  Code in the eye of the fly and
 seek to know
   the true path of the REBOL way!  :-)
 
   -jeff
 
 -- 
 To unsubscribe from this list, please send an email
 to
 [EMAIL PROTECTED] with "unsubscribe" in the 
 subject, without the quotes.
 


=
please reply to: [EMAIL PROTECTED]

__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 

[REBOL] Re: binary problem

2001-03-03 Thread Will Arp

Nenad,
Thanks a lot,
that works.

8)
Will

 
 Hi Will,
 
 Will Arp wrote:
 
 a: read/binary %callmov.r
 == #{
 23212F7573722F6C6F63616C2F62696E2F7265626F6C2F7265626F6C202D6373
 0A5245424F4C205B5D0A0A613A206C6F61642025767262696E320A633A20...
 same? a read/binary %callmov.r
 == false
 
 
 Hello 8)
 Well I was expecting a true result..
 Can please someone help ?
 
 Try with 'equal? instead of 'same? :
 equal? a read/binary %callmov.r
 == true
 
 'same? will return 'true only if the two arguments refer (or point) to the
 same memory space.
 
 Basically, 'same? applied on immutable values should work as you expected.
 
 For example with an integer! (immutable):
 a: 5
 == 5
 b: a
 == 5
 same? a b
 == true
 c: 5
 == 5
 same? a c
 == true; true !
 equal? a c
 == true
 
 but, with a string! (mutable):
 a: "foo"
 == "foo"
 b: a
 == "foo"
 same? a b
 == true
 c: "foo"
 == "foo"
 same? a c
 == false; false !
 equal? a c
 == true
 
 Is append a good way to join two binaries ?
 
 Sure, it's a good way. You can also use 'join (should be a little bit faster).
 
 HTH,
 
 DocKimbel.

-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: CPAN for REBOL

2001-03-03 Thread Bob Racko

At 05:31 AM 3/3/01 -0500, Mark Dickson wrote:

The Script Library at REBOL.com is only updated infrequently
and REBOL.org appears all but dead.

if you have an update that is overdue, bring it to my attention.
there is a subgroup of us revising the
rebol.org site to add more interactivity, etc.

we are not looking for enhancement requests
but we can accelerate true submissions of code.



I would like to enquire if anybody has the time to setup and run
effectively a Comprehensive Archive Network simlir to PERL CPAN
for REBOL scripts.

I have been working at this for the last year.

"code only when you -have- to"

Ideally, to quickly evolve a CPAN ( CrAN? CARLs? )
one would like to build on the work of others.
It should be trivial (and I don't mean get the source and fork a new 
version) to build on someone else's work and discoveries and include
that work as a foundation to your own.

As well, it probably needs to be automatic to
include the most recent version of some
other authors code within your own creations without having
to edit your mods in again.

REBOL's built in capability to 'DO a URL goes a long way toward this.

At the same time, it should be easy to
make standalone files or files with live
built-in test cases and sample values.  (an unadorned 'do runs the examples)

Working with the "N" (network) part of CPAN I realize that unlike java,
rebol does not require all things come from the same source or domain.
The author is free to trust any source they wish for 'do-ing sub-modules.

I see a more distributed system is possible.  I would like to assist in 
spreading out the central-depository approach and leave the maintainer free 
to make updates continuously.  It would be nicer if you went right to the 
source (maintainer) for certain modules or foundation code.

In that case  rebol.org  may just evolve to be
a directory of resources and module start points.


The current problem is that there is very little discipline used on this list
that would create truly modular layers or do-callable sub-modules.

We get plenty of great examples with plenty of hardcoded sample values.
Not much that can stand on its own yet give remote invokers the ability to
refine the hard-coded values beforehand without altering the authors
intended utility.  I hope to change that.  The work I have
been do-ing (pun) tries to showcase what is possible through
modular layering.



" But isn't 'do-ing over the net slow? "

It could be -- that is where caching can help.
That's where YOU (reader) can help.

This caching issue came up when I got
involved with reb-world game development.

Consider:

   do http://www.mysite.com/reboltools/hammer.r

this would load hammer.r every time across the net.
What if there were an object! or function:

   cache/do http://www.mysite.com/~bobr/reboltools/hammer.r

that would check against a local version and do that one first
and only check the net for something newer, say once a week?

The function would have to be able to distinguish hammer.r
as different from  ~jeff/somesubdir/hammer.r  without requiring
lots of subdirs on the local machine.  Perhaps a hash of the path is used.




 Controlling your cache 101

We have to be able to set bounds and timing ... I propose a setup function
with appropriate refinements:

   cache/setup/size 1024  ; nearly 10 megs

   cache/setup/recheck-every 24:0:0  ; once a day, default is once a week


An additional requirement would be that the owner of the cache be allowed 
to set which dirs were used to store which domains/subpaths

   cache/setup/location-for "jeff/somesubd"
   %tmp/bargain-basement-scripts/jeff/

so that if the owner of the local machine pleased, they could remove all
the files in a certain directory and only affect a specific (knowable)
portion of the cache.

   cache/setup/save %tmp/netcache.r

would save the current operating parameters (if any) out to disk.

   cache/setup/install %user.r

would update user.r so the cache is loaded on every callup of rebol.

   cache/setup/improve-system-do

would replace the  'do function so that all calls to 'do check the cache 
first if the argument is a URL and invoke the system one otherwise.  This 
way no coding change is required for older scripts to begin working with 
the new caching.

For other common operations:

cache/clearall
cache/setup/trace true
cache/setup/offline true   ; disable weekly recheck till back online

Finally, this has to work in /core with cgi's
cause that's where you get some of the most
steep penalties for going
back out over the net.


With that spec in mind I am looking for writers.

Of course the cache will itself be loaded as 'do able code!

I promise great fame to the writer.  If you don't have your own
website to host docache.r (or whatever you choose to call it)
I can find some hosting for you - very quick.





A properly managed resource system for REBOL scripts and examples
is 

[REBOL] Re: Spreadsheet

2001-03-03 Thread David Vydra

Mark,

This remark strikes me as rude.

David

--- [EMAIL PROTECTED] wrote:
 Well do it then!!!
 
 Who or what is stoppin  you?
 
 It would be great if you could achieve something
 outwith REBOL?
 
 Mark Dickson
 
 
 
 
 -- 
 To unsubscribe from this list, please send an email
 to
 [EMAIL PROTECTED] with "unsubscribe" in the 
 subject, without the quotes.
 


=
please reply to: [EMAIL PROTECTED]

__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/
-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: Spreadsheet

2001-03-03 Thread Volker Nitsch



 Ursprngliche Nachricht 

Am 04.03.01, 01:24:20, schrieb "Brett Handley" [EMAIL PROTECTED] 
zum Thema [REBOL] Re: Spreadsheet:


 The thought occurred to me. I actually did come across a situation 
where we
 wanted to provide spreadsheet functionality but in a very constrained
 manner. The reason being that the users were already using 
spreadsheets and
 were very nervous about causing errors. So they wanted a custom 
program
 instead, but they needed flexibility in how to define a calculation.

 We never did that app, because we were going to get a "better bang for 
buck"
 by doing other things first.

 Anyways my thoughts about doing this with Rebol:
 1) Need to build a grid based entry interface style. Once done, very 
useful
 for other Rebol applications.
 2) Need to code a graph sorting algorithm that gets as input the
 dependencies between cell calculations.

How much calculatios would be needed?
Is a left-right/up-bottom complete calculation really to slow?
Because you can enter simply rebol-code in cells,
and then dependency-chcking is hard.. 

 3) Need to provide all the little user-interface niceties that people 
expect

as a seldom spreadsheet-user, what do they expect?
Copy/paste of areas/formulas?
Or would a rebol-loop accessing cells are enough?

 from spreadsheet applications.
 4) Aim to keep as much power of Rebol as possible accessible to user 
entered
 parts of the spreadsheet.

 I think (1) is the most reusable for other applications. (2) is an
 interesting problem to solve.
 (3) may actually be the most amount of work in the project - users 
expect a
 lot!
 but (4) is a good justification for a Rebol powered spreadsheet - 
Rebol
 programming can be made visual...

 Brett.

Volker

 - Original Message -
 From: "Andrew Martin" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Sunday, March 04, 2001 8:17 AM
 Subject: [REBOL] Spreadsheet


  Has anyone thought of making a spreadsheet in Rebol/View or 
Rebol/Link?
 
  I'd really like to combine the best parts of Star Office Spreadsheet,
  Microsoft Office Excel and Lotus Improv, and merge them together with 
a
  generous helping of Rebol Script.
 
  Andrew Martin
  ICQ: 26227169 http://members.nbci.com/AndrewMartin/
  --
 
 
  --
  To unsubscribe from this list, please send an email to
  [EMAIL PROTECTED] with "unsubscribe" in the
  subject, without the quotes.
 

 --
 To unsubscribe from this list, please send an email to
 [EMAIL PROTECTED] with "unsubscribe" in the
 subject, without the quotes.



-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: CPAN for REBOL

2001-03-03 Thread Andrew Martin

 What if there were an object! or function:

cache/do http://www.mysite.com/~bobr/reboltools/hammer.r

 that would check against a local version and do that one first and only
check the net for something newer, say once a week?

 The function would have to be able to distinguish hammer.r as different
from  ~jeff/somesubdir/hammer.r  without requiring lots of subdirs on the
local machine.  Perhaps a hash of the path is used.

Probably best to write the cache like this:

Cache/Contents: [
"www" [
"mysite" [
"com" [
"~bobr" [
"reboltools" [
%hammer.r [
; Script contained for
http://www.mysite.com/~bobr/reboltools/hammer.r
]
]
]
"~jeff" [
"somesubdir" [
%hammer.r [
; Script for ~jeff/somesubdir/hammer.r
]
]
]
]
]
]
"members" [
"nbci" [
"com" [
"AndrewMartin" [
"Rebol" [
"Scripts" [
%Index.r [
; The contents of %Index.r. Note: don't look
for this, yet...
]
]
]
]
]
]
]
]

That way, if the remote file changes behaviour or requires additional files,
it's really easy to adjust the cache to reflect the changes. The cache then
saved to disk as a block in one file and easily loaded again, plus it's
readable by humans in case of problems.

Opinions? Comments? Suggestions?

Andrew Martin
ICQ: 26227169 http://members.nbci.com/AndrewMartin/
--


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.




[REBOL] Re: CPAN for REBOL

2001-03-03 Thread Andrew Martin

Volker wrote:
 Headers should have some
 [expires:  24-Mar-2001/9:56:25-8:00]

Headers should also have a redirect:
Redirect: http://Users.MySite.com/MyRebolScripts/Test.r
to cover the case where the code maintainer discovers a significant
change in refactoring is needed, or a change of site is required. For
example, my free site provider changed from Xoom to NBCi.

Andrew Martin
ICQ: 26227169 http://members.nbci.com/AndrewMartin/
--


-- 
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the 
subject, without the quotes.