r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[View] discuss view related issues

Gregg
27-Dec-2010
[10499]
If you expect to support large, dense, spreadsheets, you may want 
to minimize storage by having a name mapping interface. If the target 
is small/medium/sparse sheets, having the name explicit for each 
cell may be practical. In any case, having a alias system would be 
nice, for named cells and ranges.
DideC
28-Dec-2010
[10500x3]
>> view layout [
[     box white 327x327 draw [
[          pen logo.gif fill-pen off box 100x100 300x300
[         ]
[    ]
** Script Error: draw expected image argument of type: image pair
** Where: do-facets
** Near: draw [
    pen logo.gif fill-pen off box 100x100 300x300
]
...but this is an example from the Wiki docs : http://www.rebol.net/wiki/Pen
It error out with 2.7.7,  1.3.1, 1.2.8 so whats-up ? Is this just 
R3 Draw capability ?
Cyphre
28-Dec-2010
[10503]
you are missing the EFFECT facet in your code (the DRAW block is 
inside EFFECT block in R2) so the correct way is:

 view layout [
     box white 327x327 effect [draw [
          pen logo.gif fill-pen off box 100x100 300x300
         ]]
    ]
DideC
10-Jan-2011
[10504]
Oh my god. sorry for the mistake. Jumping from R2 to R3 syntax make 
me dumb.
GrahamC
18-Jan-2011
[10505x2]
Is there a way to set focus on a field and then send some characters 
into the keyboard buffer or something to simulate key strokes?
Or, should I be looking at some windows macro programs?
Maxim
18-Jan-2011
[10507]
you can in glass ;-)
GrahamC
18-Jan-2011
[10508]
unfortunately I can't rewrite 1000s of lines to just solve one issue
Maxim
18-Jan-2011
[10509]
the standard view doesn't have programmable events.  but you can 
set the field's data after focus...
GrahamC
18-Jan-2011
[10510]
that doesn't work .. so I'm thinking some key recorder or something
Maxim
18-Jan-2011
[10511]
what do you mean it doesnt work?
GrahamC
18-Jan-2011
[10512x4]
it's a RebGUi issue
there's a bug in my widget and i have to stuff one character in it, 
delete it and then insert the characters I want
I don't think you can insert a del
or backspace ...
Maxim
18-Jan-2011
[10516x3]
you can't generate events in normal view R2.
though you can call a face's feel if you want.
just build an object with the same fields as an event and it will 
work  :-)
GrahamC
18-Jan-2011
[10519]
is there a windows key stroke recorder?
Maxim
18-Jan-2011
[10520]
yeah it exists.  just google it.
GrahamC
18-Jan-2011
[10521x2]
hmm...maybe something else.  just control the mouse and the keyboard 
buffer
I thought Gregg did some Api work with windows... can't find it by 
googling.
ChristianE
18-Jan-2011
[10523]
Leaving all RebGUI specialities aside, can't you just patch the widgets 
FEEL/ENGAGE to allow objects being passed to it? If there is a point 
where you're in control to FOCUS the face in question, that may be 
possible.
GrahamC
18-Jan-2011
[10524]
I can't actually get focus to the face either :(
Gregg
20-Jan-2011
[10525]
My old send-keys stuff should be around somewhere. If not, let me 
know and I'll zap it to you.
Maxim
20-Jan-2011
[10526]
did it not rely on the console being opened to work?
GrahamC
20-Jan-2011
[10527]
Gregg, please send it to me
Gregg
21-Jan-2011
[10528]
Graham, sent.
GrahamC
22-Jan-2011
[10529]
Thanks .. looks like send-keys solves my problem too :)  I needed 
to send a backspace to a rebgui field to initialize it and this works
Maxim
29-Jan-2011
[10530]
for those who don't know how to change the title of a window in R2....

rebol []

win: view/offset/new layout [

 button 400x20"change window name" [ win/text: random "ogiue goiueng 
 oesigneso ginue sogine sgioun " win/changes: [text] show win]
] 200x200

do-events
DideC
31-Jan-2011
[10531]
The following code cause an error if you click on the window (XP 
SP2) :

view layout [box effect [ draw [
    pen none navy
    line-pattern 2 7 2 3
]]]

Does others could confirm the problem ?
Henrik
31-Jan-2011
[10532]
it just quits here in 2.7.7.
Oldes
31-Jan-2011
[10533]
It's known bug. At least Maxim was talking about it with Cyphre in 
OSX group a few days ago.
Dockimbel
31-Jan-2011
[10534]
Tested with View 2.7.7 & 2.7.8 on Win7/32-bit, it quits too here.
DideC
31-Jan-2011
[10535]
I always get :

Instruction at "0x7c920cce" use the memory address "0x40080000". 
The memory can't be "read".

(rougthly traduce from the French message !)
Maxim
31-Jan-2011
[10536]
yes, its a BUG in AGG, using more than 2 values in line pattern will 
cause the crash.  its the oldest AGG bug I know of.


spoke with cyphre, its possible that this will be fixed in next release 
of R2, which shoudn't take more than a few weeks IMHO.
Henrik
14-Feb-2011
[10537x2]
How does one capture whether a window is maximized or not?
I can see a maximize and a minimize event, but no restore event. 
And face/changes is cleared, when the event handler reads it. Not 
very useful.
Maxim
14-Feb-2011
[10539]
face changes is used for the internal show to optimise if/what it 
should redraw. as such its a "write only" property, reading from 
it makes no real sense.


for example if you set changes to [offset] it will move the window 
MUCH faster than if you change offset & show without it.
james_nak
10-Jun-2011
[10540]
I have a problem. Basically I need to know how to interupt a function 
that is looping. 

So this is what happens: The user presses "start" button which calls 
the printing routine. I want to be able to allow him to stop the 
process if he wishes by pressing a "stop" button. The issue is the 
face is only recording my attempts to stop. Any thoughts?
Henrik
10-Jun-2011
[10541x2]
I usually set a flag with a button and try to read the flag in the 
loop. I'm not sure if it's easy to get an immediately responding 
button, though.
perhaps if you wait a short period prior to reading the flag in the 
loop.
james_nak
10-Jun-2011
[10543x4]
Yes, I've tried to do that but it doesn't seem to work.
I'll put a wait and see
OK, I'm getting close.
Yup, the wait does the trick. Thanks Henrik.
Henrik
10-Jun-2011
[10547]
ok, cool
Maxim
10-Jun-2011
[10548]
yes, the wait allows the event system to act like an async system. 
 


just be careful though, you can get lost in concurrency and get apps 
which close all windows but don't actually close the rebol process, 
which ends up in an event deadlock.    :-)