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

World: r3wp

[View] discuss view related issues

Oldes
31-Oct-2010
[10412]
The only way how to clear the cache without loading new image is 
using:

write/binary %tmp.jpg read/binary http://www.rebol.com/graphics/carl1208-120.jpg
view layout [ image %tmp.jpg button "close" [unview/all]]
clear second second :load-image

write/binary %tmp.jpg read/binary http://www.rebol.net/photos/carl3.jpg
view layout [ image %tmp.jpg button "close" [unview/all]]
delete %tmp.jpg
Anton
31-Oct-2010
[10413]
Oldes shows that you can't just "load-image/clear", you must "load-image/clear 
imgfile", which loads a new image after clearing the cache. It offers 
no way to separate the two functionalities. Annoying, isn't it?


O  Use  clear second second :load-image , as you are, but I suggest 
doing this straight after the loading, eg.

 layout [ image %tmp.jpg  do [clear second second :load-image] ... 
 ]

O  Patch or replace LOAD-IMAGE  eg. so its IMAGE-FILE argument can 
also be NONE!

O  Patch the IMAGE style by changing the FILE function in the MULTI 
object:
	print mold get in svv/vid-styles/image/multi 'file
    so it doesn't use LOAD-IMAGE.
[ ]  Submit this deficiency to curecode.

Or  
>> view layout [image (load %bay.jpg)]
>> mold second second :load-image
== "[]"
Brock
31-Oct-2010
[10414x2]
am I stating something obvious when I say check the source for load-image?
>> source load-image
load-image: func [
    "Load an image through an in-memory image cache."
    image-file [file! url!] "Local file or remote URL"
    /update "Force update from source site"
    /clear "Purge the entire cache"
    /local image image-cache
][
    image-cache: []
    if clear [system/words/clear image-cache recycle]
    if any [update not image: select image-cache image-file] [

        if all [update image] [remove/part find image-cache image-file 2]
        repend image-cache [
            image-file
            image: either file? image-file [load image-file] [

                either update [load-thru/binary/update image-file] [load-thru/binary 
                image-file]
            ]
        ]
    ]
    image
]
Oldes
1-Nov-2010
[10416]
I was checking the source of course, without it I would not come 
with code like:
	clear second second :load-image


But it was not for the first time when I had the situation with the 
unexpected image. Of course, to use :
	layout compose [image (load %image.jpg)]

is a solution as well. I just have to remember it not be confused 
again with code:
	layout [image %image.jpg]


The problem is, that normal user who want's to just display simple 
view layout does not know that there is the function load-image.
Cyphre
1-Nov-2010
[10417]
another rokaround is:
load-image/clear http://
or load-image/clear to-url none
etc.
Maxim
2-Nov-2010
[10418x2]
anyone started work (maybe even finished) some Draw ->  SVG converter 
?


actually, even the other way round would be usefull if the above 
isn't already tackled.
if you've started one, I'd be willing to either finish it or use 
it as a reference to build a mostly complete one and give it back 
to the community on rebol.org.
Steeve
2-Nov-2010
[10420x3]
SVG -> DRAW in R3 
but not finished...
but not working anymore with the host-kit
Input: 
http://sites.google.com/site/rebolish/test-1/lizard.svg
output:
http://sites.google.com/site/rebolish/test-1/lizard-rebol.png
code:
http://sites.google.com/site/rebolish/test-1/svg.r
Maxim
2-Nov-2010
[10423]
thanks!  I'll look into it, its possible that I need it, possible 
that I don't ... I just want to know what's out there so I can take 
educated decisisons :-)
Steeve
2-Nov-2010
[10424]
I probably made a wrong choice, trying to parse the source on the 
fly instead of converting the xml source into nested blocks.
Maxim
2-Nov-2010
[10425]
I'll have to build the convertion on both sides, so converting your 
code into using rebol blocks is going to be my choice.


I already have the xml part very well covered, so I'll dive into 
this in a few days.  thanks again.
GrahamC
2-Nov-2010
[10426x2]
Max, a task for you :) http://www.the8pen.com/index.html
Saw this on Gab's facebook comments
Maxim
2-Nov-2010
[10428]
wow that's real research... seems extremely usable!
GrahamC
2-Nov-2010
[10429x2]
yeah .. I do my research on facebook
Looks doable in View and R2
Maxim
2-Nov-2010
[10431]
yes, but with patent pending, it means we can't actually do it unless 
we get a license from them.
GrahamC
2-Nov-2010
[10432]
eh??
Maxim
2-Nov-2010
[10433]
yep.
GrahamC
2-Nov-2010
[10434x2]
I don't think this sort of thing is copyrightable
otherwise we would also still be using visicalc
BrianH
2-Nov-2010
[10436]
But patentable, yes. They didn't have software patents in the visicalc 
days.
Maxim
2-Nov-2010
[10437]
of course it is. if some can patent double clicking on a portable 
device icon.. this most assuredly yes.
GrahamC
2-Nov-2010
[10438]
some countries software patents are not enforceable
Maxim
2-Nov-2010
[10439]
and in fact, this is one of the cases where a patent is used in its 
rightfull way.. this is truely an invention, original and even fully 
developped.
GrahamC
2-Nov-2010
[10440]
I doubt it .. gestures for letters have been around for a long time
Maxim
2-Nov-2010
[10441]
though the result seems easy to reproduce, the research and the original 
idea of how this is being approached is very nice.
GrahamC
2-Nov-2010
[10442]
it's evolution ... not revolution
Maxim
2-Nov-2010
[10443]
since its not really gestures in the way I'm used to understand them.
GrahamC
2-Nov-2010
[10444]
builds on prior art
Maxim
2-Nov-2010
[10445]
not really.. the only prior art it shares is in the fact that you 
scrub your fingers.. its not actually using shapes, but a very simple 
clockwise counting algorythm.
GrahamC
2-Nov-2010
[10446x2]
if you draw a semblance of a g and it turns it into a g .. what's 
new about that?
the only new thing is some lines on the screen :)
Maxim
2-Nov-2010
[10448]
you don't draw a semblence of a G... you start up and turn left or 
right from 90 to 360 degres.
GrahamC
2-Nov-2010
[10449x3]
looks like a shorthand g to me
for those who learnt shorthand
so I would say both shorthand and gestures constitute prior art
Maxim
2-Nov-2010
[10452x4]
no.. all letters are produced using the same gesture... turning clockwise 
or counter-clockwise.. its very smart.
that's it.
no special shape detection nothing actually mathy about it.
its probably doable in 100 rebol lines of code  :-)
GrahamC
2-Nov-2010
[10456]
well, I guess the answer lies in whether their patent application 
succeeds or not
Maxim
2-Nov-2010
[10457]
yep.. but patent reviewers actually do not really research these 
things for more than one hour... so unless someone challenges it, 
and the claims are different than other alternate  character entry 
solutions, then they probably have an almost certainty in getting 
it.  it will be very easy to defend also, because its SO simple and 
doesn't rely on math algorythm just a dirt simple idea which I have 
never seen before.


this being said, its possible that the idea itself isn't new within 
this research field, but I've never seen this in a commercial form 
before.
GrahamC
2-Nov-2010
[10458]
I can imagine that HP will object
Henrik
3-Nov-2010
[10459]
Did they perform the staircase test? Can it be used while walking 
up and down a flight of stairs?


Looks ok, but they made one mistake in assigning space to letting 
go of the gesture area at the center. That's too specific for a bumbling 
train ride, or where you can only pay partial attention to your device. 
Also, blind-typing and locating the center spot probably won't work. 
It's once again, not just the size of hands that are the problem, 
but the much more varied environment, in which you are operating 
your device.
GrahamC
3-Nov-2010
[10460]
You could glue a pimple on the screen
AdrianS
3-Nov-2010
[10461]
I watched the video and I'm not too impressed. Something like swype 
seems to work a lot faster. With that you define a whole word in 
one continuous stroke