AltME groups: search
Help · search scripts · search articles · search mailing listresults summary
world | hits |
r4wp | 1023 |
r3wp | 10555 |
total: | 11578 |
results window for this page: [start: 4101 end: 4200]
world-name: r3wp
Group: Linux ... [web-public] group for linux REBOL users | ||
Kaj: 27-May-2008 | If you really want to do it from the text mode console, you have to start X first. And then when you start an X app, it will open on console 7, the graphical one where X runs, so you have to switch consoles | |
Henrik: 4-Aug-2008 | are you sure the task you want to do can't be done without resorting to root? | |
btiffin: 4-Aug-2008 | Louis; do yourself a favour. Read up on chmod, chown and chgrp. In particular chmod. These aren't the easiest of topics at first (mainly due to the crap involved with the 1970's octal numbers and some poor choice of names). But after the initial weirdness the concepts are really straight forward. Read, Write, Execute across User (the owner), Group, Others (not in group) and All (world). There is an overlay of weirdness with directories and Execute (create a file in the dir) and a special mode bit etc. But again ... grunt through until your brain tells you that you get it. It's important, imho. Flailing around with sudo and su (and root powers in general) is not the safest of ways to run Linux. Potentially lowers the security to the level of your average Windows box ... nearly none. :) It can seem like a pain sometimes, but it isn't, it's part and parcel of a secure os. BG has tainted the world to think it is inconvenient. Much like a lock maker giving everyone the same key. A stupid "convenience" that wouldn't fly when it came to your car or house or bank, but PC users have grown up with and expect for reasons I have never understood. (This last part is simple ranting - sorry about that) | |
Louis: 5-Aug-2008 | btiffin, thanks. I like Linux. I did a lot of experimenting when I first made the switch, and that helped speed up the learning process. There is so much to learn that I doubt that any one person could ever know it all, but I've already learned enough to be able to do more than I was able to do with windows after many years of use. My rant: I hate the Windows registry file! | |
Anton: 18-Aug-2008 | Yep, I just spent at least 4 weeks learning how to compile and install a video driver in Kubuntu. I had to do a distro upgrade because the graphics card I bought was too new for the OS. I became a little more proficient in the console over the last four weeks. :) | |
Louis: 26-Aug-2008 | I've been using that script for 6 years without a problem, so I suspect that this present problem has something to do with Linux. | |
Gabriele: 5-Sep-2008 | yes, color or something like that is what i was thinking. maybe some kind of "mode". i need to look at some ansi esc sequence docs, i'll eventually do that if noone beats me to it. | |
Robert: 4-Oct-2008 | Which leads me to the next question: How do you handle Rebol scripts that are used on Windows and Linux regarding returns? Do you just use the LF or CRLF or CR (OSX)? | |
Henrik: 4-Oct-2008 | The launch environments are different in that the shebang path is used by the shell to know what to do with the script. You can also run a REBOL script in the linux terminal with: rebol -qs script.r and it will be the same script as under Windows. It might look a little ugly, but you could wrap your windows REBOL scripts in a shebang script. | |
Kaj: 14-Oct-2008 | Graham, why do you say JeOS finds your NICs? ifconfig not showing them would seem to indicate it doesn't | |
Anton: 16-Oct-2008 | Wait a minute, before the upgrade, I did a *hardware* upgrade, replacing the motherboard and 32-bit cpu for a 64-bit one. This is when 'eth0' changed to 'eth1' and I had to muck about to fix it. <--- This is probably related to the network problems. (So much happened since then, I keep forgetting about this.) My solution is probably to do a fresh 64-bit install. | |
kcollins: 16-Oct-2008 | Yeah, Linux still has work to do on wireless networking. | |
Robert: 6-Dec-2008 | Guys, thanks a lot. As always there is more than one way to do it. :-) | |
Gabriele: 22-Dec-2008 | Petr, if you are writing your own video player, maybe you can do something, but don't expect it to be easy (well, maybe you can just stick to one specific version of the driver). Why do you want to do this? Isn't software playback good enough? 720p H264 works fine on this machine which is an old Athlon XP 2600+. Do you really need 1080p? If so, isn't a cheap laptop MB able to give you that in software already? | |
Kaj: 25-Dec-2008 | Probably the most you could do is try to cross-compile ORCA for it | |
Robert: 15-Mar-2009 | But how to handle source-only packages? I have an other system with everything on place. But how to do the install on the production server? | |
Robert: 15-Mar-2009 | Any idea how to best do it? | |
Anton: 15-Mar-2009 | To achieve the above you need to do 2 things: 1) Log files that were modified or added during the compile/installation (or otherwise find them after the installation). 2) Copy to the production server. | |
Anton: 15-Mar-2009 | To do 1, it may help to use this console command after an install. alias recent='find . -type f -printf '\''%TY-%Tm-%Td/%TT %p\n'\'' | sort' | |
Anton: 15-Mar-2009 | We can't be the only ones wondering how to do this, so I will check google for a tool to monitor installs.... | |
Anton: 18-Mar-2009 | Well, in Rebol/View 2.7.6.4.2, I can paste the multiply sign (copied from ascii-math.r) straight into the console and it shows correctly. In a field, however, it shows incorrectly, eg. if I try to paste it in the field: view layout [f: field] I get two characters, 'Ã' and a dotted box, displayed instead. The binary information is correct, it's just not rendered correctly, for if back in the console I do: probe f/text then I get the multiply symbol displayed correctly again. So it looks like View face/text rendering is expecting 8-bit ascii of some encoding. Probably ISO/IEC_8859-1 | |
Anton: 1-Apr-2009 | So on the surface it looks easy to do, actually. | |
Anton: 2-Apr-2009 | I don't think so. The window managers sit on top of the X Windows system and get it to do the basics - opening windows etc. | |
amacleod: 2-Apr-2009 | Firefox has kiosk mode where window frames and titles disappear...may work differnetly than normal windows without titlebars..maybe simpler to do | |
Pekr: 3-Apr-2009 | Anton - I know. My point is, that if SDL can do it, cross platform, looking into their source will reveal actually HOW they do it, no? They have to call some Linux underlying code, to achieve no-border window. ... | |
Anton: 3-Apr-2009 | Not Rebol callbacks. A DLL built using C is injected using LD_PRELOAD when running any executable. The executable I'm interested in is Rebol, of course. This injected code intercepts calls to XCreateSimpleWindow (which creates the X Windows window), and adds some properties to it, including one which stores the process id of the application opening the window. This means that each X window can be ensured to have the process id of the application that opened it (which is otherwise not mandated by X). So I could do that to any program and it would ensure that there is a way to get the process id. I'm doing it to Rebol, and this means it is now possible for another DLL function (called from Rebol) to scan all the windows opened on the X display and see which one has the Rebol process id. All you need is the process id, and this is easy to do with a very small DLL function call. | |
amacleod: 5-Apr-2009 | I have a program I would like to run on a netbook (Small screen 800x480) so I do not want to lose any realestate to title bar... (I know it can come with XP but for another $50) Also, I like the idea of the application "taking over" the netbook as if this device and the App are one. It's for use by non-techies so as little interaction with linux as possible is desired... | |
Izkata: 9-Apr-2009 | Seems likely other setups also wouldn't crash, but I wouldn't put it past Gnome to do something strange | |
Pekr: 17-Apr-2009 | So I just installed glorious UBUNTU Server edition. Installation went OK, but after 15 minutes of usege, I have big WTF? Are those ppl crazy? This is total piece of crap. You can't have X-Windows easily running there. There is NO visual administrative tool intalled by default. No webmin, but Ebox. At least Docs state how to install/run Ebox. It does NOT work, it is missing some packages. I am also left with my user name, and the SUDO. But - can you do everything by SUDO? How do I find out my real root password? I am really not an experienced Linux user, but I could manage that stuff with old Fedora in 2004. Why Ubuntu gets so much attention? | |
Pekr: 17-Apr-2009 | well, the server "works" somehow, as I can reach its web. But I am not hardcore linux guru to go with pure console. So I wanted to add webmin, but noticed there is Ebox equivalent, but was not able to install it. The package mechanism is strange too - too much packages. I liked "yum update" with Fedora - it simply installed needed patches. Here I tried aptitude but how do I know from so many packages, what I need to install. I need very simple mechanism to just apply security patches, nothing more, like with Windows :-) | |
Gabriele: 18-Apr-2009 | what do i need to install - that is automatic. sudo apt-get install package-name | |
Gabriele: 4-May-2009 | 2.4 / 2.6 - I don't know if anything special is needed to do that. you can very likely compile both kernels in order to make them compatible with each other, and it's also possible to handle this in the userland. | |
Gabriele: 5-May-2009 | even when going from 2.4 to 2.6? I guess that if they do that, they must have tested it. i'm not aware of debian being able to keep multiple versions of programs though, so if it's installing a new version of a program, most likely it will remove the old one. (it can keep multiple versions of the same library, but not always) | |
Janko: 8-May-2009 | Doc: I have /lib/ and /lib64/ -- do you think that lib are 32b libs? or do I have to install them ... the client told me now he thinks admin installed the 32b libs at his vps | |
Janko: 8-May-2009 | rebol now works, but I have a problem with cheyenne , something similar to what Doc said before -------------- [root-:-www]:/usr/share/cheyenne# ./cheyenne ** Script Error: Library error: /lib/libc.so.6: wrong ELF class: ELFCLASS64 ** Where: do-cache ** Near: all [ any [ exists? libc: %/lib/libc.so.6 exists? libc: %/lib/libc.so.5 ] libc: load/libra... [root-:-www]:/usr/share/cheyenne# ldd ./cheyenne libm.so.6 => /lib32/libm.so.6 (0xb7ef7000) libdl.so.2 => /lib32/libdl.so.2 (0xb7ef3000) libc.so.6 => /lib32/libc.so.6 (0xb7da1000) /lib/ld-linux.so.2 (0xb7f24000) [root-:-www]:/usr/share/cheyenne# | |
Janko: 8-May-2009 | So I just need to move to the latest cheyenne ... now I have the reason to do so :) | |
Robert: 9-May-2009 | Any idea how to enable utf8 support? Do I need to "convert" the existing filesystem? | |
Maxim: 18-May-2009 | no clue !! I havn't even started putting content yet :-) working on new ssh-admin upload/download/shortcut features and then remark_mod. until remark_mod is working, no content will be visible. forcing myself to implement what I've been wanting to do for years ;-) | |
amacleod: 18-May-2009 | What are we talking about here, Maxim? What will this allow you to do exactly? | |
Janko: 27-May-2009 | Any ideas how to do this? I am trying to compile it now on my other VPS which is 32bit and copy file to the 64bit vps but I have no idea if this will work | |
Ashley: 22-Jul-2009 | What distro works best with sdk-2706042.tar.gz "out of the box" (with regards to rebview and fonts)? I just need something I can quickly install under VirtualBox and do some basic cross-platform REBOL GUI development/testing ... without having to hack it to make it work. | |
Ashley: 23-Jul-2009 | OK, so I've downloaded Ubuntu 9.04 (64bit) and got it running under VirtualBox, then I download and untar/zip the REBOL SDK and open a console session. cd to the REBOL dir and do a chmod +x and type ./rebview ... which comes back with a "file or dir not found message" ... anything else I need to do to get REBOL working? Oh, and what font looked best with RebGUI in your opinion? | |
Gabriele: 24-Jul-2009 | In any case, it's easier to do a "sudo apt-get install ia32-libs" than do a new installation, no? :) | |
Ashley: 25-Jul-2009 | OK, I've got it running under a clean install of Ubuntu 32bit. Now, how do I determine what scaleable fonts REBOL can actually use? (%/usr/share/fonts/truetype/freefont/ doesn't seem to have all that many ... and they look pretty ordinary atsize: 72). | |
Graham: 3-Aug-2009 | Perhaps the easiest thing to do is to redefine NOW based on a NIST offset. | |
Anton: 15-Aug-2009 | Doc, or anyone, do you know how to write a proxy for system/ports/input ? | |
Anton: 15-Aug-2009 | Hmm.. sounds a bit too complicated for now - might have to wait for another day... but, how do you think I would replace system/ports/input ? By just : system/ports/input: my-port ? | |
Anton: 15-Aug-2009 | console-port: open/binary/no-wait console:/ console-port/awake: func [port /local ch][ if ch: pick port 1 [ ;print ["Console awake trapped key:" to-char ch "(" ch ")"] either ch = #"^V" [ ; Ctrl+V call "xclip -o -selection clipboard" ; Three different types of clipboards: "primary", "secondary" or "clipboard". ][ insert system/ports/output to-char ch ] ] return false ; Does not cause return from WAIT (DO-EVENTS). ;true ; Does cause return from WAIT (DO-EVENTS). ] insert system/ports/wait-list console-port if error? set/any 'err try [ do-events ][ print mold disarm err ] close console-port remove find system/ports/wait-list console-port | |
Anton: 15-Aug-2009 | I don't really know what I'm doing with ports. I need more information. All I can get it to do is shutdown rebol on keypress. | |
Anton: 22-Aug-2009 | (It's unclear to me the relationship between a port and its subport. I know the port manages the opening/closing of its subport, but how can the port in lines mode transfer individual chars from its buffer into the subport ? Or do they both receive from the same input simultaneously automatically?) | |
yeksoon: 28-Aug-2009 | do u have direct access to the server? | |
Henrik: 28-Aug-2009 | I would love to see data mining tools that can detect such attempts at access in the access log without having to read through the log. Do they exist? | |
Pekr: 2-Sep-2009 | I am moving few domains of my friend to my server. However - he wants to access email, which means, I need to provide him with authenticated smtp. I have my old sendmail in simple mode - simply relying allowed from local 10* network, but not from the outside. Has anyone succesfull configured sendmail, so that it would use authentication by username, password? My friend sent me following link, but I don't understand, what should I do :-) Hopefully I don't need to recompile sendmail :-) http://www.sendmail.org/~ca/email/auth.html | |
Pekr: 4-Sep-2009 | Thinking about providing my brother with some webmail option on my Linux server. In the past, I used simple Squirrel mail. Then I know some ppl do use Horde. Now my friend suggested me a Zimbra. Isn't Zimbra a little bit too much for just an occassional web option to pop3 account? | |
Pekr: 1-Oct-2009 | Gabriele - because Linux sucks. Because if it would be easy, Janko would not post his questions here. I user REBOL, because it provides me with simplicity to what I need to do. I use Mikrotik, because it is absolutly best low-cost FW/shaper/whatever, used by 90% small WISP? | |
Gabriele: 1-Oct-2009 | so, what the hell has that to do with Janko's problem (a firewall for his server)? | |
Pekr: 1-Oct-2009 | It might have nothing to do with Janko's problem. But - I saw you suggesting him ShoreWall, and in that regard I did mention Mikrotik, because I have experience with it, and simply put - nearly all WISP are using it, and that means something. Some ppl do replace Cisco's with it. The system is no-brainer - just insert CF with MT, boot, and there you go. If some node dies, you can replace it in 10 minutes, no virtualisation or advanced technique used, just its clever design. Besides that - MT is still Linux underneath ... | |
Gabriele: 2-Oct-2009 | the issue is not whether it's free or not. the issue is that they are REMOVING features for no reason at all. Why not just add their own windows UI (that of course it's only for windows! they could not do like anyone else and make a web interface that works everywhere...) on top of a custom linux distribution that ALSO gives you the ability to do whatever you want with it IF you know how? | |
Pekr: 2-Oct-2009 | It has NOTHING to do with MT and your claims are simply false. If you are so brave, then go, and replace your bad MT with another Debian Box. I wonder, if it would make you more happy. MT is not bug-free, I never claimed anything like that. My MT suggestion was relatad exactly to the SIMPLICITY factor. You call it complex? Man - it is like you never used REBOL, right? MT brings simplicity to the wifi providing, that some other solutions are not even funny to suggest. MT Linux abstraction is like a VID dialect upon Linux - yes, it can't do everything. But I can't come-up with anything it does not do for me for 99% of my usage cases. Yes, I noticed your OpenVPN problem, not supporting UDP, and yes, it sucks, but it does not mean that MT does not serve its purpose. | |
Gabriele: 3-Oct-2009 | Also, PLEASE, I beg you, do *read* what I write. I never said my problems are due to mikotik. I said my problems are due to my ISP not knowing what they are doing. You said that mikrotik allows "normal" people to set up a WISP. Right, they do, and the result is that they waste MY time *because* they know nothing about this job. This was *your* claim, and it seems to be consistent with what I am seeing. | |
Gabriele: 3-Oct-2009 | The criticism I made to RouterOS was very targeted and very simple, and you of course completely ignored it. I said two things: 1) there is absolutely no reason they had to add the stupid shell they have when you connect via SSH 2) there is no reason why what they do could not have been implemented on top of debian, or any other distribution, thus allowing people who know what they are doing to provide extra services that are beyond what's in their default configuration. That is just a stupid choice. So, most people don't care or need, and for them MT may be a good choice. That does not make them a good alternative to a linux box, neither a good alternative to Janko's problem above, and from what you say they may be even making things worse. | |
BudzinskiC: 22-Oct-2009 | Thanks for trying to help :) With font problem, do you mean something like a missing font? I got these installed: ttf-ms-fonts, ttf-dejavu, ttf-bitstream-vera, xorg-fonts-100dpi, xorg-fonts-75dpi, and xorg-fonts-misc. Any idea what kind of font would be missing for the Word Browser? | |
BudzinskiC: 25-Oct-2009 | Yeah I started looking at the code. It's a bit hard to debug for me though. The error doesn't give any line number, it just says "near show main". I searched for "show main" and found three occurances in the source. I'm completely new to REBOL so going through everything in the code would take me quite some time without being able to narrow it down first because everything looks alien to me and I have to look it up to see if something in the script looks wrong. Is there some good tutorial available on debugging REBOL code? Or is there some trick to find out the last line that was executed? I do have access to the terminal at that point, the view is frozen but the terminal still accepts commands. | |
Pekr: 26-Oct-2009 | Is the situation really so bad? Well then - there is no other chance than to do it on per distro basis then, and isolate what is common for more platforms, and then do special configs ... | |
BudzinskiC: 26-Oct-2009 | I never had any trouble with Java + Swing working everywhere, but I only recently started using Java for real (about a year ago I think) so maybe it's just gotten a lot better now and was awful in the past ^^ But I guess it also depends a lot on what you are trying to do. Programming shouldn't be generalized. There are so many vastly different categories of programming (database, web, server, games, system, scripting, image/video processing, automation, A.I., embedded, etc.) that your mileage may vary depending on your area of interest. And don't get me wrong, I don't want to bash REBOL in any way. Apart from being completely new to the language which means that I can't really say if it's bad or good yet, I wouldn't be here if I didn't think it was useful and had potential :) Thankfully I already had some basic experience with Scheme, Clojure (a lisp) and Haskell so that REBOL's syntax didn't come as a shock for me :) | |
Henrik: 26-Oct-2009 | I guess a demonstration of its stretch is rebcode, which I had no idea was possible. It won't be in R3, but the fact that it's even possible to do in a scripting language and was implemented in as short time as it was is a great demonstration of how generic REBOL is. | |
Gabriele: 27-Oct-2009 | Budzinski: REBOL's shortcomings wrt to "multiplatformness" are mainly due to Carl not having the time/resources to really keep all platforms up to date. Design wise, I think that we don't have the problems Java had/has; they do, though, have enough manpower to fix all of them, no matter how awful things end up being. ;) | |
Henrik: 27-Oct-2009 | I've read the explanation multiple times, but BrianH knows it better than me. It has something to do with how functions are implemented in R3, which would make rebcode work slower in R3. Therefore it's better to spend time perfecting extensions, so you can write time critical code in C and use that instead. Rebcode is not for beginners anyway (but it did bring up that oldschool feeling for a while :-)). | |
Robert: 3-Dec-2009 | I would like to switch to debian but don't know how I can do this on a running system... | |
Henrik: 15-Dec-2009 | Actually i thought it was a clone of the iPhone, but it turned out to be a thin shell above Ubuntu with a less usable browser and Gnome windows constantly popping up in a jarring way above the UI. I hate these papermaché solutions that only superficially tries to do something for usability. | |
Maxim: 17-Dec-2009 | pekr... one problem today is that people have come to an assumption that software programs itself. I don't know where that is coming from, but in ALL real projects... at some point, you actually do have to raise your sleeves and put a little effort into it. | |
Pekr: 17-Dec-2009 | If 10 ppl can spend 50, it might be enough for someone to do fix here or there ... | |
Oldes: 22-Dec-2009 | Can't do nothing as everything stops on trying to stop the service using the script which does not exists | |
Gabriele: 30-Dec-2009 | you need to chroot and install more packages, I guess. you need to do an actual installation, and not just a bootstrap. | |
Barik: 2-Feb-2010 | I have the #!/usr/local/bin/rebol line and such in there. The problem is that I'm not sure how to make the script then go into the background again like a daemon would do. It stays at the foreground when I call it from something like init.d. | |
Barik: 2-Feb-2010 | Okay, that may do what I need it to. REBOL does some interesting things which I haven't quite figured out when I do something like CTRL + Z, bg, etc. | |
Barik: 31-Mar-2010 | Oh boy, didn't mean to do that. Looks like AltME in VMWare on CentOS had some initial weirdness as well. Sorry about that! | |
Group: Rebol School ... Rebol School [web-public] | ||
Henrik: 8-Feb-2009 | kib2, let REBOL decide what is what, by asking the datatype: >> series? [a b c] == true >> series? "abc" == true You can do that, because REBOL has so many different datatypes, allowing you to be precise in your expression. | |
Henrik: 8-Feb-2009 | Geomol, the reason you do that, is of course to avoid garbage collection of said "locals"? | |
Geomol: 8-Feb-2009 | Henrik, no, not really because of garbage collection, because the garbage collector doesn't collect words defined 'globally', right? I do it, because it's good programming practise to not have many globals. :-) | |
Henrik: 8-Feb-2009 | kib2, since you can bind contexts everywhere, even inside other contexts, they are not really secure and so you can't make things really private to a context. Modules will do that, I believe. | |
Geomol: 8-Feb-2009 | Janko, I've been thinking about this problem too, and I'm not sure, what's best. Is it good enough, what we can do with functions today? Like: >> old-add: :add >> add: func [a b] [either string! = type? a [join a b] [old-add a b]] >> add 4 5 == 9 >> add "Hi " "John" == "Hi John" Now ADD can also be used to join strings. | |
Geomol: 8-Feb-2009 | Janko, yes, that would be cool to do. | |
Janko: 8-Feb-2009 | Geomol: something like you and I described would probably be possible to do in library , probably not that effective but it should surely be possible | |
Anton: 8-Feb-2009 | Steeve, yes, you can do that, but then if other people want to use your code, they must use the accessors you have written, which effectively expands the language. | |
Geomol: 8-Feb-2009 | kib, :-D Do you expect me to remember, how postscript works. ;-) I have to think a bit now ... | |
Geomol: 8-Feb-2009 | Better to remember where do look something up, than to remember all that is in the book. | |
Steeve: 8-Feb-2009 | if i had to do, i will use the draw engine with logical bitmap operators to find the points | |
kib2: 8-Feb-2009 | nice, thanks. Now, I'm looking for something like hashtables (key-value). Is there something special, or do I need to use blocks ? | |
Geomol: 8-Feb-2009 | A simple timing function to test performance: time: func [:f /local t][ t: now/time/precise do f now/time/precise - t ] | |
Geomol: 8-Feb-2009 | Yes, it takes some more work to do it in R2. | |
DideC: 9-Feb-2009 | I also give it a try. Not really a browser, just an HTML renderer with view/draw. But rendering HTML is a very complex thing to do, especially the layout, tables... So it is only able to render texte styles. | |
Geomol: 11-Feb-2009 | kib, you write: title: [ 1 6 "=" copy title to newline ] In that, you use the word title for two things, so you destroy your intention. Change one of them to another word (remember to do it again further down your code). | |
Vladimir: 14-Feb-2009 | thanks Anton... this is perfect for what I want to do..... :) | |
Anton: 16-Feb-2009 | Another way to make tunnel effects. do http://anton.wildit.net.au/rebol/demo/rebol-stargate1.0.2.r | |
Pekr: 16-Feb-2009 | BrianH: could that work as a plug-in for e.g.? Or - do you think it is possible to have even several VMs that way? Simply a compiler? Maybe we could even find some small C compiler to be included with REBOL? (if that would make sense) | |
Pekr: 16-Feb-2009 | Thanks. I found original site. Well, 100KB to have cross-platform compiler? Nice. It will not prevent devs to write cross-platform code, but those who would like to do so, could do so, and that is important ... Licence - LGPL, so it might work OK as an extension ... | |
Steeve: 16-Feb-2009 | in R3, replace the code (at tail) by: screen: system/view/screen-gob unless system/view/event-port [ system/view/event-port: open [scheme: 'event] ] pixel_size: 1x1 grid_size: 160x100 img: make image! probe gob-size: (grid_size * pixel_size) append screen ekran: make gob! [offset: 50x50 size: gob-size draw: [image img]] do [ boja: pick paleta 15 change/dup skip img 0x0 boja grid_size * pixel_size for i 0 127 1 [ for yy -50 49 1 [ for xx -50 49 1 [ rr: square-root (((xx + 0.5) * (xx + 0.5)) + ((yy + 0.5) * (yy + 0.5))) if ((rr > 14) and (rr < 50)) [ zz: (900 / rr) pozicija: (pixel_size * (grid_size / 2 + (as-pair xx yy))) dubina: :zz - 18 / 46 red: to-integer dubina * 63 + 1 red: red + i red: to integer! red // 63 / 2 + 1 either xx = 0 [ugao: arctangent 999999999999] [ugao: arctangent (yy / xx)] either xx >= 0 [ugao: ugao + 360 // 360] [ugao: ugao + 180] ugao: to-integer ugao / 360 * 63 ugao: ugao // 32 ugao: ugao + 1 p: level/:red/:ugao boja: pick paleta p change/dup skip img pozicija boja pixel_size ] ] ] show ekran ] ] | |
Steeve: 16-Feb-2009 | see that, i do a scaling in R3: screen: system/view/screen-gob unless system/view/event-port [ system/view/event-port: open [scheme: 'event] ] pixel_size: 1x1 grid_size: 160x100 img: make image! probe gob-size: (grid_size * pixel_size) append screen ekran: make gob! compose [offset: 50x50 size: (gob-size * 4x4) draw: [scale 4 4 image img]] do [ boja: pick paleta 15 change img boja grid_size for i 0 127 1 [ for yy -50 49 1 [ for xx -50 49 1 [ rr: square-root ((xx + 0.5) * (xx + 0.5)) + ((yy + 0.5) * (yy + 0.5)) if ((rr > 14) and (rr < 50)) [ zz: 900 / rr pozicija: grid_size / 2 + as-pair xx yy dubina: zz - 18 / 46 red: i + to-integer dubina * 63 + 1 red: to integer! red // 63 / 2 + 1 either xx = 0 [ugao: arctangent 999999999999] [ugao: arctangent (yy / xx)] either xx >= 0 [ugao: ugao + 360 // 360] [ugao: ugao + 180] ugao: to-integer ugao / 360 * 63 ugao: ugao // 32 ugao: ugao + 1 p: level/:red/:ugao boja: pick paleta p change skip img pozicija boja ] ] ] show ekran ] ] | |
Anton: 16-Feb-2009 | The layout produces a face hierarchy like this: window face IMAGE face BUTTON face So that's two faces needing buffers refreshed whenever you do SHOW window. It's faster to have just one face (the window face). window face |
4101 / 11578 | 1 | 2 | 3 | 4 | 5 | ... | 40 | 41 | [42] | 43 | 44 | ... | 112 | 113 | 114 | 115 | 116 |