Search found 54 matches

by TheMartian
Sat May 01, 2010 2:03 pm
Forum: Hollywood bugs
Topic: Callback functions don't like ':'
Replies: 5
Views: 3787

Re: Callback functions don't like ':'

Hi Just for completeness... Some experiments have now taught me that the 'self' parameter can be mimicked by taking advantage of the 'userdata' parameter because you can pass the object itself in 'userdata'. Then the callback function can refer to 'msg.userdata in the same way you would use the 'sel...
by TheMartian
Tue Apr 27, 2010 8:04 pm
Forum: Hollywood bugs
Topic: Callback functions don't like ':'
Replies: 5
Views: 3787

Re: Callback functions don't like ':'

Hi Yes, that might be the way to go. For now I have sidestepped the issue and just created an eventclass with two methods. One is for handling keys and one for mouse events. Each method decides by itself or is fed the object to act on, and then each object class has its own 'keyaction' or mouseactio...
by TheMartian
Mon Apr 26, 2010 5:22 pm
Forum: Hollywood bugs
Topic: Callback functions don't like ':'
Replies: 5
Views: 3787

Re: Callback functions don't like ':'

Hi Yes, as you say it effectively passes a parameter representing the object itself, and callback function don't like that, so I guess that kills of that approach. I was just wondering if I could pass a 'self' parameter as part of a callback function because I was getting into programming in Hollywo...
by TheMartian
Sun Apr 25, 2010 10:03 pm
Forum: Hollywood bugs
Topic: Callback functions don't like ':'
Replies: 5
Views: 3787

Callback functions don't like ':'

Hi I am not sure if this is the correct behaviour or not, since callback routines don't allow explicit parameters. But what about the implicit 'self' parameter? In the example below it works if I write: SetTimeOut(Nil,x.cheese,1000), but SetTimeOut(Nil,x:cheese,1000) fails. x={} Function x:cheese() ...
by TheMartian
Wed Apr 14, 2010 8:20 pm
Forum: Hollywood bugs
Topic: ShowDisplay() fails if display outside of visible screen
Replies: 3
Views: 2951

Re: ShowDisplay() fails if display outside of visible screen

Hi I noticed this because I was playing with the sceen dump utility I created using Hollywood some days ago based on the new desktop dump command and put on this site. The screen dump utility gets around the problem by only copying the part of the selected area inside the visible display (and actual...
by TheMartian
Sat Apr 10, 2010 8:30 pm
Forum: General programming
Topic: A screendump program the Hollywood way
Replies: 0
Views: 1938

A screendump program the Hollywood way

Hi Here is a Screen dump program that will dump any selected area of the Desktop to the RAM: disk as a .BMP file. Multiple dumps are possible. I kind of like the idea using of a Hollywood display as the marker for which area to dump. It saves a lot of work because displays can be resizable and dragg...
by TheMartian
Sat Apr 10, 2010 7:53 pm
Forum: Hollywood bugs
Topic: ShowDisplay() fails if display outside of visible screen
Replies: 3
Views: 2951

ShowDisplay() fails if display outside of visible screen

Hi If I move a display partly outside the visible screen and later hide and display it i get a message like this: Unable to change displaysize to 1024 x 1024 ...(if that is the size of the display). The code below triggers the error as my display has the dimensions 1920 x 1200. So 300+1024 is beyond...
by TheMartian
Sat Apr 10, 2010 11:00 am
Forum: Hollywood bugs
Topic: GrabDesktop does not grab sections of Desktop
Replies: 1
Views: 1940

Re: GrabDesktop does not grab sections of Desktop

Hi again

Ouppps - SOrry. Just got it... :lol:


I need to write it like this:

GrabDesktop(10,{x=x,y=y,width=w,height=h})

So - no problem after all.

regards
Jesper
by TheMartian
Sat Apr 10, 2010 10:56 am
Forum: Hollywood bugs
Topic: GrabDesktop does not grab sections of Desktop
Replies: 1
Views: 1940

GrabDesktop does not grab sections of Desktop

Hi I was programming a small utility to grab a section of the desktop and store it as a BMP picture. For this I used the GrapDesktop function. However it seems to ignores the parameters in the table (x, y, width, height) and just copies the entire desktop whether the parameters are there or not. I u...
by TheMartian
Sun Apr 04, 2010 8:17 pm
Forum: General programming
Topic: How to make Powerbar?
Replies: 3
Views: 3358

Re: How to make Powerbar?

Hi again It occurred to me that it might be better to actually come up with some code. So here we go... :P regards Jesper /* This is an example of one approach to creating a powerbar that is colored using a gradient running from blue (representing 0%) to red (representing 100%) */ /* First we create...