[Gambas-user] How to move an object within a form

Fiddler63 mx4eva at ...626...
Mon Jan 18 19:38:15 CET 2010


I would like the user to be able to move the drawingarea around within the
form.
The drawingarea(s) will eventuality  be created dynamically, when I get
around to understand that part as well.
Image a bunch of boxes like a mindmap, which you can move around on the
screen (within the form).
Kim



Fabien Bodard-4 wrote:
> 
> what do you want to do exactly... i don't understand :/ (english is
> not my primary language !)
> 
> 2010/1/18 Fiddler63 <mx4eva at ...626...>:
>>
>> I'm trying to move an object within a form.
>> The following code allows me to move the form, but not the object within
>> the
>> form, ie when I click on the mouse I can move the form around on the
>> screen,
>> but no the object within the form.
>>
>> Any suggestions ?
>>
>> PRIVATE $MX AS Integer
>> PRIVATE $MY AS Integer
>>
>> PUBLIC SUB DrawingArea1_MouseDown()
>>  $MX = Mouse.ScreenX - ME.X
>>  $MY = Mouse.ScreenY - ME.Y
>> END
>>
>> PUBLIC SUB DrawingArea1_MouseMove()
>>  ME.Move(Mouse.ScreenX - $MX, Mouse.ScreenY - $MY)
>> END
>> --
>> View this message in context:
>> http://old.nabble.com/How-to-move-an-object-within-a-form-tp27209201p27209201.html
>> Sent from the gambas-user mailing list archive at Nabble.com.
>>
>>
>> ------------------------------------------------------------------------------
>> Throughout its 18-year history, RSA Conference consistently attracts the
>> world's best and brightest in the field, creating opportunities for
>> Conference
>> attendees to learn about information security's most important issues
>> through
>> interactions with peers, luminaries and emerging and established
>> companies.
>> http://p.sf.net/sfu/rsaconf-dev2dev
>> _______________________________________________
>> Gambas-user mailing list
>> Gambas-user at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gambas-user
>>
> 
> ------------------------------------------------------------------------------
> Throughout its 18-year history, RSA Conference consistently attracts the
> world's best and brightest in the field, creating opportunities for
> Conference
> attendees to learn about information security's most important issues
> through
> interactions with peers, luminaries and emerging and established
> companies.
> http://p.sf.net/sfu/rsaconf-dev2dev
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user
> 
> 

-- 
View this message in context: http://old.nabble.com/How-to-move-an-object-within-a-form-tp27209201p27214892.html
Sent from the gambas-user mailing list archive at Nabble.com.





More information about the User mailing list