tag:blogger.com,1999:blog-190908862024-03-08T19:51:20.598+01:00rebolekBlog about REBOL written in terrible English. This is not Carl's blog, this one is independent ;)Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.comBlogger17125tag:blogger.com,1999:blog-19090886.post-26364066852799048572013-05-22T08:24:00.001+02:002013-05-22T08:25:23.839+02:00Drag'n'drop in R3GUI<div dir="ltr" style="text-align: left;" trbidi="on">
Back to using this blog (before I move somewhere else again)!<br />
Let's start with something simple: @GrahamChiu was interested to see how to do drag'n'drop in <strong>R3GUI</strong>. Here is it:<br />
<script gapi_processed="true" src="https://gist.github.com/rebolek/5618033.js"></script>
<br />
<h2>
Some explanation</h2>
<code>DRAGGER</code> is style used for dragging. It's simple box, but you can use anything you want.<br />
<h3>
Dragger / on-click</h3>
You need to define <code>ON-CLICK</code> actor to catch <code>MOUSE-DOWN</code> event:<br />
<pre><code>on-click: [
if arg/type = 'down [
return init-drag face arg/offset
]
]
</code></pre>
This will initialize and return the dragging object.<br />
<h3>
Dragger / on-drag</h3>
You also need to add <code>ON-DRAG</code> actor to process movement:<br />
<pre><code>on-drag: [
face/gob/offset: arg/offset - arg/base
show face/gob
]
</code></pre>
Argument for this actor is the drag object defined in <code>ON-CLICK</code> actor with <code>INIT-DRAG</code> function.
The drag object holds original position and new offset (and also some other fields that are not interesting for this simple tutorial).<br />
<h3>
Dropper / on-drop</h3>
For faces that accept our <code>DRAGGER</code> face we need to implement <code>ON-DROP</code> actor:<br />
<pre><code>on-drop: [
append-content face arg/face
return true
]
</code></pre>
This actor just adds our <code>DRAGGER</code> face to target panel and returns <code>TRUE</code> to indicate everything went well.<br />
<h2>
Notes</h2>
If you drop the <code>DRAGGER</code> on face that has no <code>ON-DROP</code> defined, <code>DRAGGER</code> will return to original position automatically. <br />
<h2>
Conclusion</h2>
As you can see, it's fairly easy. Feel free to ask about details!</div>
Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com1tag:blogger.com,1999:blog-19090886.post-1159261747504422142006-09-26T11:07:00.000+02:002006-09-26T11:14:58.276+02:00<span style="font-weight: bold;font-family:verdana;" >What's new???</span><span style="font-weight: bold;"><br /><br /></span>I don't know. Everybody's waiting for some new release. No new releases, no new articles in my blog. SAD.<span style="font-weight: bold;"><br /></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com29tag:blogger.com,1999:blog-19090886.post-1142243148836206202006-03-13T10:38:00.000+01:002006-03-13T10:45:48.853+01:00<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/1479/1883/1600/HNLP.jpg"><img style="margin: 0pt 0pt 10px 10px; float: right; cursor: pointer;" src="http://photos1.blogger.com/blogger/1479/1883/400/HNLP.jpg" alt="" border="0" /></a><br /><span style="font-weight: bold;">Literar programming</span><br /><br />I was interested in literar programming and MakeDoc3 Gabrielle is now working on, but I was missing some code I can try. So I took great <a href="http://hem.bredband.net/martinjohannesson/hypernotes/">HyperNotes</a> software and patched it with one new keyword - SCRIPT. On save, HyperNotes saves not just the notes file but all code between SCRIPT tags as REBOL script. Now I'll try to rewrite RebC (more on RebC later) using HyperNotesLP. You can see screenshot of my patched HyperNotes on the right. It show my simple index.r editor.<br /><br />BTW, tommorow I'm thirty, so as John Lennon said, you cannot believe me from that date.Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1139990281815635802006-02-15T08:55:00.000+01:002006-02-15T08:58:01.816+01:00So...<br /><br />So...Competition is over, you can read the results on its page, I'll write something about Compo in my next blog. I've switched to MEPIS from Windows so I've got lot of maintaince work right now, sorry for no new posts.Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1136459025943983682006-01-05T12:02:00.000+01:002006-01-05T12:03:45.953+01:00<span style="font-family: arial; font-weight: bold;">Blog is not dead</span><br /><br /><span style="font-family: arial;">I'm just working on demo so I've no time to publish news. Wait till 10.1.2005</span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1134979084274004382005-12-19T08:50:00.000+01:002005-12-19T08:58:04.283+01:00<span style="font-weight: bold; font-family: arial;">REBOL DEMO CONTEST</span><br /><br /><span style="font-family: arial;">Great</span><span style="font-weight: bold; font-family: arial;">!<span style="font-weight: bold;"></span></span><span style="font-family: arial;"> RDC 2005! Write best graphical demo in REBOL, fit it in 32 768 bytes and you can win:</span><br /><br /><span style="font-family: arial;">1. iPod Video</span><br /><span style="font-family: arial;">2. XBox360 (or Mac Mini)</span><br /><span style="font-family: arial;">3. SDK or Command license (1st and 2nd too)</span><br /><br /><span style="font-family: arial;">Isn't it great? Everybody's probably working on a demo now as deadline is on December 31st, 11:59:59 GMT. Submit your demos using dedicated web page (wait a moment, there's no such a web page still and the deadline is less than two weeks away!) and then wait.</span><br /><br /><span style="font-family: arial;">And if you're waiting you can wait for Core 2.6.3 which is comming in January 2006. Together with View 1.3.3? Who knows. But we can hope.</span><br /><br /><span style="font-family: arial;">So don't expect many new blogs till new year, as I'm trying to win iPod or XBox ;)</span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1134547729720463582005-12-14T09:04:00.000+01:002005-12-14T09:08:49.730+01:00<span style="font-family:arial;"><span style="font-weight: bold;">Mail file sharing</span><br /><br />Because I'm writing scripts on more than one computer I need to sync files somehow. I can use flashdisk for synchronization, but USB is not always available or I forget my flashdisk at home, so it's not always the right option.</span><br /><span style="font-family:arial;">Or I can use ftp to upload and download files. But at the end I've got lots of different directories with different versions, because I have no intelligent file structure.</span><br /><span style="font-family:arial;">I was inspired by Google filesystems for win and lin so I decided to use some freemail (gmail preferably) for my scripts maintaing. Unfortunatly, Gmail needs some authentication, SSL or what and SSL under <span style="font-weight: bold;">REBOL </span>needs Command and Command needs 350$ to buy.</span><br /><span style="font-family:arial;">So I found another freemail provider that offers both non-authenticated SMPT and POP and therefore is OK for <span style="font-weight: bold;">REBOL</span> (btw. remeber the old <span style="font-weight: bold;">REBOL</span> example? send <luke>[luke]@[rebol].[com] read <a href="http://www.rebol.com/">http://www.rebol.com</a> ? Hard to do with all the authetications required today.) and I started coding.<br /><br /></luke></span><span style="font-family:arial;">The result is a small application called <span style="font-weight: bold;">%rspace.r</span> that can upload file to repository, download newest version from repository, or you can get list of all files in repository and finally, if you're happy with your script, you can publish it on www/ftp. All this with documentation in less than 6kB.</span><br /><span style="font-family:arial;">All you need is <span style="font-weight: bold;">REBOL</span> and mail account cappable of SMTP/POP without authentication. It's good to have an FTP account for publishing files but that's not required. If you do not have an mail account, I've set up one on <a href="http://seznam.cz/">seznam.cz</a>, user 'rebolspace' and pass 'spacerebol' for testing this application (it's built in, so you can start testing right after download).<br /><br /></span><span style="font-family:arial;">Remember, it's just alpha, does not have many features, but it works, I can write something here, update it there and have all the versions accesible from everywhere. It's written for <span style="font-weight: bold;">REBOL</span> scripts so with big projects it's going to be very slow and unusable, but for small project (and most <span style="font-weight: bold;">REBOL</span> scripts are really small) it's probably good.<br /><br /></span><span style="font-family:arial;">So download it form <a href="http://krutek.info/rebol/rspace.r">http://krutek.info/rebol/rspace.r</a> (stable) or <a href="http://rebolspace.sweb.cz/rspace.r">http://rebolspace.sweb.cz/rspace.r</a> (latest published version).<br /><br /></span><span style="font-family:arial;"><span style="font-weight: bold;">WARNING</span>: because <span style="font-style: italic;"><rebolspace>[rebolspace]@[seznam].[cz]</rebolspace></span> is open account it won't be wise to use it ordinarily. Please, if you like it, set up your own account and use it instead of built-in one.</span><br /><span style="font-family:arial;">And remember: all suggestions and fixes are welcome.</span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com73tag:blogger.com,1999:blog-19090886.post-1133902985371552592005-12-06T21:49:00.000+01:002005-12-06T22:05:13.726+01:00<span style="font-weight: bold;font-family:arial;" >Convole<br /><br /><span style="font-weight: bold;"></span></span><span style="font-family:arial;">I wrote there are probably no new features in View 1.3.2 . That's not true, there's new effect - convolve. It's a standard covolution matrix that can be applied on face as any other effect. Usage is following:<br /><br /><br /><span style="font-family:courier new;">view layout [<br /> image http://krutek.info/pix/fotky/roland.jpg effect [<br /> convolve [<br /> -1 0 0<br /> 0 1 0<br /> 0 0 0<br /> ] 0 128 true<br /> ]<br />]<br /><br /><span style="font-family:arial;">Format of convolve is:<br /> <br /><span style="font-family:courier new;"> matrix [block!] divisor [number!] offset [number!] preprocess-grayscale [logic!]</span><br /><br />There were rumours for long time that convolve is already part of View, but only internally without user-interface, despite this being true, convolve is finally official part of View and that's great. So let's look more suprises hidden in this new release! :))<br /></span><br /></span></span><span style="font-weight: bold;font-family:arial;" ><span style="font-weight: bold;"></span><br /></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1133858097240401412005-12-06T09:27:00.000+01:002005-12-06T09:34:57.250+01:00<span style="font-weight: bold;"><span style="font-family: arial;">SDK 2.6.2 released!<br /><br /></span></span><span style="font-family: arial;">Gabriele said yesterday, that new SDK should be out "very soon". I didn't thought he was talking not in days but in hours :) So it's out, with >50 bugs fixed (still no change-log but it surely comes later). Anything new? As I supposed, no. We have to wait for 1.4.0 .And, there won't be new betas, because "everybody was in favour of this idea". Erhm, me not, I like betas. But View 1.3.2 is out and that's good. RT still has to change their web pages to reflect it everywhere, because thy still offer 1.3.1 as newest version.</span><span style="font-weight: bold;"><span style="font-family: arial;"><br /></span></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1133789882735118292005-12-05T14:30:00.000+01:002005-12-05T14:38:02.746+01:00<span style="font-weight: bold;"><span style="font-family: arial;">1.3.2 should be out very soon.<br /><br /><span style="font-weight: bold;"><span style="font-weight: bold;"></span></span></span></span><span style="font-family: arial;">Said Gabriele on AltMe. If you look at <a href="http://www.rebol.net/cgi-bin/rambo.r">RAMBO</a>, there's cca. 40 fixed bugs for View 1.3.2/Core 2.6.2 .<br />So what can we expect in 1.3.2 ?<br /><br /></span><span style="font-family: arial;"><span style="font-weight: bold;">rebcode</span> - no. It's not secure now, should be part of 1.4</span><span style="font-family: arial;"><br /><br /><span style="font-weight: bold;">rebservices</span> - don't know. Maybe client/server will be part of 1.3.2 . That should be great addition.</span><span style="font-family: arial;"><br /><br /><span style="font-weight: bold;">new datatypes</span> - probably not. You can find unicode! , rebcode! and vector! in recent alphas, but they'll be probably removed.<br /><br /><span style="font-weight: bold;">rich text</span> - there was no alpha demo so I think it has to wait for 1.4.<br /><br />And what is expected release date of 1.4? Nobody knows.<br /><br /><br /><br /></span><span style="font-weight: bold;"><span style="font-family: arial;"><span style="font-weight: bold;"></span><br /></span></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1133769128943658722005-12-05T08:48:00.000+01:002005-12-05T08:52:08.953+01:00<span style="font-family: arial; font-weight: bold;">Two news.<br /><br /></span><span style="font-family: arial;">I've got two news. One good and one bad. First the good one.</span><span style="font-family: arial; font-weight: bold;"><br /><br /><span style="font-weight: bold;"><span style="font-weight: bold;"></span></span></span><span style="font-family: arial;">Graham Chiu has released his <a href="http://www.compkarori.com/emr/">Synapse EMR</a><br /><br />From the announcement:<br /><br /><br />Graham's EMR is a free powerful multi-user electronic medical records</span><br /><span style="font-family: arial;">system that uses the open source RDBMS Firebird.</span><br /><br /><span style="font-family: arial;"> * Multi-user across LANs and the Internet.</span><br /><span style="font-family: arial;"> * No installation or registry changes.</span><br /><span style="font-family: arial;"> * Small client and server footprint.</span><br /><span style="font-family: arial;"> * Rich GUI client.</span><br /><span style="font-family: arial;"> * Encrypted network traffic.</span><br /><span style="font-family: arial;"> * Unlimited number of patients and staff.</span><br /><span style="font-family: arial;"> * Tablet PC friendly.</span><br /><span style="font-family: arial;"> * Image friendly - include images and drawings in your consults</span><br /><span style="font-family: arial;"> * Medication Database Included.</span><br /><span style="font-family: arial;"> * Read codes included.</span><br /><span style="font-family: arial;"> * Easy Custom Form creation</span><br /><span style="font-family: arial;"> * Paper management - store scanned documents</span><br /><span style="font-family: arial;"> * MS Word integration</span><br /><span style="font-family: arial;"> * LaTeX integration<br /><br /><br />And now the bad one. Carl is thinking about not releasing beta-versions. Sad, sad, sad.</span><span style="font-family: arial; font-weight: bold;"><span style="font-weight: bold;"></span><br /></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1133335645072977802005-11-30T08:12:00.000+01:002005-11-30T08:27:25.086+01:00<span style="font-weight: bold; font-family: arial;">REBServices</span><br /><br /><span style="font-family: arial;">Yesterday I played a bit with <a href="http://www.rebol.net/rebservices/">REBservices.</a><br />(Grrr, I have to start new line because blogger's editor seems to be really buggy.). It's a cool concept for computer colaboration over network (or even locally). Altought it's a bit paint to make it work now (it's because of documentation, alpha stage and it's not built in right now), it's really great. And guess what happend. I've started %checker.r and it said RebServices documentation has been updated! Old quick start document is now called <a href="http://www.rebol.net/rebservices/services-start.html">developer's doc</a> and there's new <a href="http://www.rebol.net/rebservices/quick-start.html">quick start</a> (really quick one :) Also, interesting (but little confusing ;) is Volker's <a href="http://polly.rebol.it/test/test/rebservices/">RebServices corner.</a><br />It's great to have something like RebServices and Rebcode, they are great additions to REBOL. Can't wait for View 1.4.0.<br /><br /><br /></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1132830088277095732005-11-24T11:42:00.000+01:002005-11-24T12:05:53.913+01:00<span style="font-weight: bold;">Bitmap tracer<br /><br /></span><span style="font-family:arial;">Yesterday Oldes released nice program, bitmap tracer. ( <a href="http://box.lebeda.ws/%7Ehmm/rebol/projects/vectorize/latest/vectorize.r">http://box.lebeda.ws/~hmm/rebol/projects/vectorize/latest/vectorize.r</a> ). It's written in rebcode and the algorythm is his own, not a implementation. He's using it for converting bitmap fonts to vector ones for usage in his REBOL/Flash dialect. And because it's Oldes, the usage is somehow tricky :)</span><br /><br /><span style="font-family:courier new;">do http://box.lebeda.ws/~hmm/rebol/projects/vectorize/latest/vectorize.r<br /><br />probe vectorize http://box.lebeda.ws/~hmm/rebol/projects/vectorize/latest/img41.gif<br /><br /><span style="font-family:arial;">If you try that code you can see result is not very REBOLish, a block of numbers. It's the coordinates in [x y x y ...] format, because rebcode cannot handle pair!. Erhm, pardon, rebcode cannot handle pair! ??<br /><br /><span style="font-family:courier new;">>> a: rebcode [x][pick y x 1 print y]</span><br /><span style="font-family:courier new;">>> a 1x1</span><br /><span style="font-family:courier new;">1<br /><br /><span style="font-family:arial;">Seems it can :) Oldes has separate function for conversion of his row of numbers to pair! so usage seems like that:<br /><br /><span style="font-family:courier new;">probe ctx-vectorize/to-pairs vectorize http://box.lebeda.ws/~hmm/rebol/projects/vectorize/latest/img41.gif<br /><br /><span style="font-family:arial;">Yes, great. Unfortunately, the result is somehow scaled and shifted, so somebody should correct 'vectorize function to support pairs or correct 'to-pairs function not to shift and scale result.<br /><br />But these are just minor problems, they're result of Oldes' coding style. The main thing is that it's now possible to natively convert bitmap images to vectors. And that's great!<br /></span></span></span></span></span><span style="font-family:arial;"><span style="font-family:lucida grande;"></span></span><br /></span><span style="font-weight: bold;"></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com64tag:blogger.com,1999:blog-19090886.post-1132748753407678332005-11-23T13:20:00.000+01:002005-11-23T13:25:53.413+01:00<span style="font-weight: bold;">Checker works!</span><br /><br />So my REBOL-pages checker seems to work. Today it says: Page http://www.rebol.net/rebservices/services-start.html has been changed on 23-Nov-2005/8:26:30 . Great! I checked that page and unfortunatly I haven't got an old copy so I cannot check directly what has been changed. So i looked at the page and it says: <b> Updated: 9-Nov-2005 </b>. Hm, my checker works bad? That's impossible! But wait, look at the bottom of the page! What does it say? <span style="font-weight: bold;" class="tail">Copyright 2005 REBOL Technologies - <a href="http://www.rebol.com/">MakeDoc2 by REBOL</a> - 23-Nov-2005 </span><span class="tail">. Ha, so I was right! It has been changed! And that's the final proof that something is still happening at REBOL Technologies and that's great. :)<br /><br /><br />Hm, not very informative post :)</span><span style="font-weight: bold;" class="tail"><span style="font-weight: bold;"></span><br /></span>Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1132578269977982132005-11-21T13:52:00.000+01:002005-11-21T14:04:45.556+01:00<span style="font-weight: bold;">Where is a rodmap?</span><br /><br />Where is REBOL's roadmap? What can we expect in new version? And when is this version comming out? Is the best way for finding out new verison to check http://www.rebol.net/builds/031/ everyday? Does "doc Friday" mean that we can get new docs only on Fridays and not on every Friday? And same with Q&A Wednesdays?<br /><br />And last, but not least, will REBOL someday hit 1.000.000 pages in Google?<br /><br />PS: Hm, there are changes in docs, but they're nowhere mentioned. Going to write some checker.Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1132425474130258532005-11-19T19:28:00.000+01:002005-11-19T19:37:54.136+01:001.3.61<br /><br />So new alpha version is out! And this time with some informations on what has been changed. Rebcode is now rebound so I can continue with my synthesizer. I'm reading that list now and it seems that lot of things has been changed in 1.3.60 so I have to dig deeper in it.<br /><br />That's all for today, my girlfriend had a birthday party yesterday, Cyphre was there with Petra, so I'm really tired today.Anonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0tag:blogger.com,1999:blog-19090886.post-1132313209655569692005-11-18T12:20:00.000+01:002005-11-18T12:26:49.660+01:00This is my first REBOL blog ;) I'm not using Carl's bolgger right now, because I've had problems setting it up on my server, I'll try that later.<br /><br />I'm running this blog just to keep some informations about REBOL together.<br /><br />So today new version of REBOL (1.3.60) has been found on REBOL.NET. There's new SIGN opcode for rebcode and some internal DRAW changes to forthcomming support of Rich-Text. More? Don't know, rebservices are still not part of REBOL (probably still too alpha) and rebcode binding bug is there too. Didn't test sound, but this is still buggy too probably. But as I heard, sound is needed for AltMe 2.0, so we can expect some changes soon.<br /><br />That's all for now, more later and hopefully on REBOL's own blogging system.<br /><br />REBolekAnonymoushttp://www.blogger.com/profile/07918682821646817276noreply@blogger.com0