Ok, the french gave me flash-backs to high school, which (temporarily) made me more unstable than I already am mentally, so I took the lazy way out and google'd itrichmond62 wrote:C'est possible, mais Je cherche chaque chance pour une méthode trop simple,Flexibility often needs complexity...
mais Je suis paresseux
Translation Google wrote:It is possible, but I seek every chance for a method too simple,
But I'm lazy: D
Aligning the edge of an image
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Re: Aligning the edge of an image

Re: Aligning the edge of an image
Well I must agree with you completely being a beginner 
Thank you again.
Bidge
Thank you again.
Bidge
Re: Aligning the edge of an image
Hello again.
I have studied your script and attempted to add a forth
image to the group. I managed to do it but for some reason
I have to click twice before the forth image goes into place?
Can someone have a look to see what I have done wrong?
Ideally I would like to add up to 6 images across the top and 6 images
below that can all be adjusted with two margin factor? if possible?
Maybe there is an easier way?
Thanks
Bidge
I have studied your script and attempted to add a forth
image to the group. I managed to do it but for some reason
I have to click twice before the forth image goes into place?
Can someone have a look to see what I have done wrong?
Ideally I would like to add up to 6 images across the top and 6 images
below that can all be adjusted with two margin factor? if possible?
Maybe there is an easier way?
Thanks
Bidge
- Attachments
-
- DragWithSpacing.zip
- Drag multiple images with spacing
- (664 Bytes) Downloaded 235 times
Re: Aligning the edge of an image
Well...after a lot of searching I managed to come up with a rather simple solution 
Cheers
Bidge
Code: Select all
on mouseUp
set the top of img "W2" to the top of img "W1"
set the left of img "W2" to (the right of img "W1") + 10
set the top of img "W3" to the top of img "W2"
set the left of img "W3" to (the right of img "W2") + 10
set the left of img "W4" to the left of img "W1"
set the top of img "W4" to (the bottom of img "W1") + 10
set the left of img "W5" to the left of img "W2"
set the top of img "W5" to (the bottom of img "W2") + 10
set the left of img "W6" to the left of img "W3"
set the top of img "W6" to (the bottom of img "W3") + 10
end mouseUpBidge
Re: Aligning the edge of an image
Hi Bidge,
There is no group in your stack and mousedown in cd script is not called because each img catch itattempted to add a forth image to the group
If you want move all controls of a group you maybe could move group instead controls of groupMaybe there is an easier way?
https://alternatic.ch
Re: Aligning the edge of an image
Thank you Jean-Marc.
I managed to get the result without using a group with your help.
Saving a text file that sets the locations, width etc of each image
is now my next hurdle: ( I posted in another thread earlier).
http://forums.livecode.com/viewtopic.php?f=7&t=29485
Cheers
Bidge
I managed to get the result without using a group with your help.
Saving a text file that sets the locations, width etc of each image
is now my next hurdle: ( I posted in another thread earlier).
http://forums.livecode.com/viewtopic.php?f=7&t=29485
Cheers
Bidge
Re: Aligning the edge of an image
I made your script more flexible but more... complicated
Who is the laziest ?
Who is the laziest ?
Code: Select all
on mouseUp
doAlignImg 2,3,10,10 --pNbRow,pNbCol,pMargeH,pMargeV
end mouseUp
on doAlignImg pNbRow,pNbCol,pMargeH,pMargeV
put the height of img "W1" into tHeight
put tTlC into depTR
put pNbRow * pNbCol into tNbTot
put 10,10 into depTR
repeat with i = 1 to tNbTot
put "W" & i into tImg
set the topleft of img tImg to depTR
put the topright of img tImg into depTR
add pMargeH to item 1 of depTR
put i mod pNbCol into tReste
if tReste = 0 then
put 10 into item 1 of depTR
add (tHeight + pMargeV) to item 2 of depTR
next repeat
end if
wait 1 milliseconds
end repeat
end doAlignImg
https://alternatic.ch
Re: Aligning the edge of an image
Hi David,
when in the script editor, hit TAB from time to time, then you will get these nice indented scripts like the ones from Jean-Marc!
AND we can read them better.
Best
Klaus
when in the script editor, hit TAB from time to time, then you will get these nice indented scripts like the ones from Jean-Marc!
AND we can read them better.
Best
Klaus
Re: Aligning the edge of an image
Wow. It astounds me how you can think of such clever ways coding Jean - Marc!!!
Oh....thank you Klaus
Regards
Bidge
Oh....thank you Klaus
Regards
Bidge
Re: Aligning the edge of an image
Thanks for the flowers.
I confess a big debt to some mentors of this forum
I confess a big debt to some mentors of this forum
https://alternatic.ch
