Space evenly movieclips with different heights?
I have the following code, which works well when all the boxes have the same height. The fundamental point is that I have three boxes on the stage, 10 pixels apart. If you click and drag the boxes above or below the other, they reorganize.
// based off Dynamic Stacking AS3 @ http://blog.soulwire.co.uk/code/open-source/dynamic-stacking var mcArray:Array = [mcA, mcB, mcC]; var mcSpacing:int = 10; goStart(); function goStart() { for (var i:int = 0; i < mcArray.length; i++) { mcArray[i].y = (mcArray[i].height + mcSpacing) * i; mcArray[i].addEventListener( MouseEvent.MOUSE_DOWN, boxPress ); mcArray[i].addEventListener( MouseEvent.MOUSE_UP, boxRelease ); } } function boxPress(e:MouseEvent):void{ e.currentTarget.startDrag(); e.currentTarget.parent.addChild(e.currentTarget); } function boxRelease(e:MouseEvent):void { e.currentTarget.stopDrag(); moveBoxes(); } function moveBoxes():void { mcArray.sortOn( 'y', Array.NUMERIC ); for (var i:int = 0; i < mcArray.length; i++) { mcArray[i].x = 350; mcArray[i].y = (mcArray[i].height + mcSpacing) * i; } }
How to do it if the boxes are different heights, while keeping the same functionality? I know that magic is in this line:
mcArray[i].height + mcSpacing
But I'm not strong enough math skills to understand.
This line contains the problem, but you can call it magic if you're a glass - half-full type. If you have different heights, you have to stack things starting with 0 and adding to the height of each object (plus 10) each time. This line as expected assumes that the height never varies, so it's just multiplying the same height for each new position.
Try...
function moveBoxes (): void {}
mcArray.sortOn ("y", Array.NUMERIC);
var YCourant: Number = 0;
for (var i: int = 0; i< mcarray.length;="" i++)="">
mcArray [i] .x = 350;
mcArray [i] there = currentY;
currentY += mcArray [i] .height + mcSpacing;
}
}
Tags: Adobe Animate
Similar Questions
-
Tables of Images with different heights, causing the removal of Menu
OK, I posted this issue in the Council of LabVIEW before I realized that it was associated with Vision. I made some progress, narrowing of the cause, so I thought it would be best to start a new post here. Here is the original post:
http://forums.NI.com/T5/LabVIEW/blank-pop-up-menus/m-p/3281194#M958610
I'm running into a problem with all of my menus of LabVIEW to shutter when I create arrays of images where the heights do not match. I have attached a vi I created to illustrate the issue. In this document, I take a starting image and then extract subsets of it. Because I don't know how much I'll have to check out until the moment of execution, I'm subpictures in an array. What I've discovered, is that if the heights of subpictures don't match, I get a weird bug that causes all the menus in LabVIEW empty. This includes all right click pop up in the façade, block, or Project Explorer diagram and drop-down selections as for enums and ring controls. It also includes the file menu at the top of the window.
Rerun this vi with subpictures equivalent height or no subpictures corrects hidden menus. In addition, running IMAQ Dispose (with Boolean true of images) corrects the problem.
I'm relatively new to the Vision, so I don't know if I'm missing something basic, but please let me know what you think. Is there a better way to do this?
Thank you
Tim
Hi Tim,.
Thanks for reporting this problem. I have reported as a bug.
I recommend using a Cluster or the KING for manual zoom toolbar. If you want to use an array, each element of the array must maintain the same amount of zoom. (Similar to each LED in a table must have the same color.)
Sorry you came across this bug.
Kind regards
-
Hello
Thank you for taking the time to read this! Yesterday that I tried to connect to an HDTV using VGA instead of someone else, worked well. Buy a vga cable today and connected to my 1080 p full hd Phillips and got a BSOD almost instantly. I tried some things and managed to do the work! Played skyrim for a little and left the laptop in sleep mode. Came, open upward and the screen stayed black, nothing I could do to get a Visual.Now, whenever I connect the cable I get a BSOD, it works with any other laptop, excludes the cable and television.I have updated all drivers in the list, checked my drive for errors using the good chkdsk, smart status on the disk is good, all withdrew. I know for a fact that my laptop works fine with extra monitors, we use all the time on my internship and as stated, it worked yesterday on another TV.Features of the laptop:ASUS n73jn
processor Intel i5 460 mNVIDIA geforce 335 mWindows 7 64 bit4 GB ddr3 RAMthe HDMI port is dysfunctional, just a few flickering screens filled with black lines, that's why I try vga. My guess is the hdmi port is DOA, but did not have a hd tv up to 2 years after purchase.
News of the capture of blue screen:==================================================Dump file: 093012-44382 - 01.dmpCrash time: 30/09/2012-18:57:22Bug Check String: SYSTEM_SERVICE_EXCEPTIONBug check code: 0x0000003bParameter 1: 00000000' c0000005Parameter 2: fffff880'074259 cdParameter 3: fffff880'029f90a0Parameter 4: 00000000'00000000Caused by the driver: igdkmd64.sysCaused by the address: igdkmd64.sys + 1e29cdDescription of the file:Product name:Company:Version of the file:CPU: x 64Plant address: ntoskrnl.exe + 7f1c0Stack address 1:The stack address 2:Address 3 the battery:Computer name:Full path: C:\Windows\Minidump\093012-44382-01.dmpNumber of processors: 4Main version: 15Minor Version: 7601The dump file size: 262,144==================================================Thanks for your time!
Greetings,Joachim
Sorry, I was a little confused with the HDMI and VGA - continues to be the same advice.
Looks like you have isolated to a hardware problem. With the Intel graphics card is not posted, I have to wonder if the hardware problem is with the graphics card Intel
FWIW - we have seen a number of overheating problems with the graphics from nVidia on your model. Make sure the laptop is on a hard surface - and I would also use a filling of cooling (if possible) to ensure that the system is not overheating.
Install a new copy of Intel video drivers is probably the most important thing to do now - and ensure that this card appears in Device Manager (and check in the nVidia PhysX tab to see if it appears here - even though I'm not familiar with this program).
Try the video stress tests here: http://www.carrona.org/addldiag.html
They can show that there is a hardware problem - but a lot of this will involve what video card works at the time of the test (even once, I don't have a lot of experience to make systems to change video card).Good luck!
-
Call taskflow even twice with different parameters - as two regions in JSFF
Hi all
I need to reuse a taskflow in two regions of a page JSFF fragment. I will be of different settings for this workflow based on the region. What I see is that the taskflow makes twic, but both the taskflows show the same State (the State for the second set of parameters). Is there a way by which I can assure that the taskflows can be reused for different context on the same page JSFF dynamically.
Ex. JSFF has 2 regions based on the same taskflow - but the taskflow settings are different for the two regions. Now, when the page runs, the two regions show the same user interface as the second region. It looks like the AM, your were interviewed again and the first run of time VO got overloaded.
Attempted parameters of transaction taskflow by changing it to "Always start a new Transaction" and it does not work.
Any suggestions?
Thank you
SriniTry to select * 'No controller Transaction' * and
Uncheck the options
(1) share data with calling taskflow controls
(2) no savapoint on the entry of work flowThank you
Nini -
Master of different heights to match the corresponding page?
In my site, I have several pages with different heights. Should I create a lot of masters with different heights to match the corresponding page?
Hello
You have one create one page of Mater.
As you add content to pages, the foot moves downwards and will increase the height of the page. So it is not necessary to create multiple master pages.
Kind regards
Sachin
-
NATting even address public ip with two periods of internal investigation with different ports
Hi people,
Can I use the same public IP for two internal investigation periods different with different ports and I can even user public IP for two periods of different internal investigation with the same ports
static (inside, outside) tcp 115.248.153.252 192.168.22.19 6303 6303 netmask 255.255.255.255
static (inside, outside) tcp 115.248.153.252 http 192.168.22.19 http netmask 255.255.255.255
static (inside, outside) tcp 115.248.153.252 http 192.168.22.20 http netmask 255.255.255.255
static (inside, outside) 115.248.153.252 tcp https 192.168.22.20 https netmask 255.255.255.255
static (inside, outside) tcp 115.248.153.252 192.168.22.21 6303 6303 netmask 255.255.255.255
static (inside, outside) tcp 115.248.153.252 http 192.168.22.22 http netmask 255.255.255.255
Concerning
Vesta
"Everybody is genius." But if you judge a fish by its ability to climb on a tree, he will live his entire life, believing that this is stupid. "No, you cannot use the same public ip address NAT on two internal IP address different using the same port.
static (inside, outside) tcp 115.248.153.252 192.168.22.19 6303 6303 netmask 255.255.255.255
static (inside, outside) tcp 115.248.153.252 192.168.22.21 6303 6303 netmask 255.255.255.255
For the static PAT 2 above for example, when traffic is coming to 115.248.153.252 IDE oucederomsurlesecondport 6303, ASA would not know if NAT it back to 192.168.22.19 or 192.168.22.21, because both use the same port.
-
I try to use a square twice side by side on my site, and they are sensitive, but as they have a different amount of content in them, they are different height. How do I make them the same height so they dimensionnera always evenly?
Here is an example of what I want to do.
Here is the css and html I use;
. Half-width {} content
Width: 50%;
Float: left;
Max-width: 675px;
Max-height: 338px;
}
. {Texthalf}
Width: 80%;
height: 80%;
margin: 10% 10%;
}
< div class = "Half-width-Content" style = "" background-color: # 2793 3; ">"
< div class = "Texthalf" >
< h1 > < font color = "White" > did you know? < / police > < / h1 >
< hr > < / h >
< h6 > < font color = "White" > Hacel has combined 100 years of experience in the lighting industry < / police > < / h6 >
< hr > < / h >
< / div >
< / div >
And this is what I get now;
Thank you
First - make sure you include a link to the jquery library in your page head tags:
And then paste the code I provided after him.
-
Find the space between the word with different endings and figures
Hello
I am trying to find a way to find spaces between the words and numbers.
I'm limited to only use the word "WORD" (capital or small capitals) with different endings like - ing s y and more (using \S+).
I wrote something like (? i) (? < = WORD\S +) \s(?=\d+) but this does not work due to some limitations of advanced search, I think?
Any suggestions?
Peter
On the other hand, I think that.
-
How to align objects in a path while scattering objects in space even with a decrease in size?
Hello
I am facing following problems:
I'm suppose to draw a spiral, and on this path I want to align a symbol to her (in my case a circle).
Now, I've found two ways how to him.
First of all, I can use the brush palette and then apply my symbol to it. but the problem is the size circles are the same, but I need the circle to get the smaller toward the center of the spiral
Second approach I took, I have used the merge options between two objects that I attach also a path. So I could solve the problem on the reduction of the size but has now another problem appear: the gaps between the circles are not same. I would like to have the same spaces.
So now my question is: How can I fix this my problem?
To better visualize my problem, you can consult this screenshot here: http://goo.GL/PEvZI
If anyone can give me a tip or a trick, I would be very appreciation there.
Thanks in advance...
Kind regards
Natla
You're welcome, Natla.
As in many cases, it makes a big difference what is the exact task, and the responses reflect the understanding of it.
As I understand the images and explanations, it would take a linear growth of the circles, distributed with a constant, possibly no zero distance between them.
From the I proposed a way to get a linear growth of the circles, with a constant distance (zero or not zero) between them, which would operate independently the proportions, so things could be adjusted.
The effect of transforming, as suggested by James, gives a more simple solution to the simpler task of exponential growth of circles and zero distance between them; with different proportions it will give increasing distance, or overlap.
-
Both adf shares VO even with different params on the same screen
Hello everyone,
My current problem is that I need to create a screen with several sharing the same VO graphics but with different settings for each of them.
Lets assume I want to use EmployeesVO to show the 2 graphs on the same page jspx.
A chart will display all the salaries of employees for the "Marketing" Department and the other will show all the salaries of employees for the Department 'IT '.
Remember, I want them both on the same screen.
The read-only VO will look like this:
SELECT First_Name
Salary
Employees
WHERE department_id =: p_dept
To do this, I did the following:
For each graph, I created an iterator.
For each iterator I created an ExecuteWithParams. (a receiver "Depto Marketing" and anther receive "IL Depto")
For each ExecuteWithParams, I created an InvokeAction.
When executing the application all the graphs show the same information. All of them show only one (the last in the list of executables InvokeAction) Department.
The question is: how to keep each graph has their own parameter on the same screen?
I use Windows 7 x 64 SP1 JDeveloper 11.1.2.1.
Thanks in advance!Why not add 2 instances of the same original version of AM. For each instance of defined the different VC.
-
Disk space is full with 143 GB free space
Hello
I found a strange math calculations to Apple here. My disk space is filled with 143 GB free space.
Here's the new math = 507 GB Apps + 119 movies GB 50 GB + 38 GB Audio 143 GB of space free Photos Plus 500 GB
I use MacBook Pro (retina, 15 inch, mid-2014) with Mac OS X 10.11.4 running
Thank you
Kiran
Hi Kirin, for more information on the other category in the view of storage , see this support article.
There seems to be a bug in the about this Mac Look storage tab > system report > storage. It's probably different.
Omni DiskSweeper can show you the exact size and location of all your files. It will be the inventory of your disc from files that occupy more space. It can also give you a fairer read disk space than the Finder or storage tab of the about this Mac. If you want you can even delete files from OmniDisk Sweeper. But beware, some items may be important for your system.
For more information about the category others in storage to display, see this support article.
-
ASM diskgroup with different disc size
Hello
DB: 10.2.0.4
Operating system: AIX 5.3 64-bit L
I have installation on 10g RAC ASM with node 2. It has the only Eve on ASM.
Total DB size is 250 GB.
Total size of FRA is 700 GB.
My FRA diskgroup to archivelog (also holds multiplex controlfile) each size of 50 GB drive. Even if I set the retention period for 1 day, backup to disk, rman getting failed, due to space issues. So I manually delete obsolete data report and rerun backup.
I want to add the workspace to FRA diskgroup regarding adding disks to FRA diskgroup. But, I have 100 GB drives available , it's not the same waist size of current existing FRA disc (50 GB).
Here's my question
(1) that I can Add the size different to the same diskgroup disc ?. If I add, are there performance problems?
My all data files are out of FRA diskgroup and there are someother diskgroup.
(2) if FRA diskgroup 50 GB and 100 GB of disks, and then how the archivelog and backup data will be erased?
Will the data stored up to 50 GB in all disks in FRA, even * 100 GB * disc is?.
(3) while doing recovery with different size of disk at diskgroup, what kind of problems can I face in performance wise?
(4) can I remove any diskgroup 50 GB disks and add the 100 GB drive, so that I can increase the size of the disk in the same diskgroup?. I'll remove it and add at the same time.
(5) add disks redundant external diskgroup , I'm ok with the following query?
ALTER DISKGROUP FRA add DRIVE ' </dev/rhdsk1 >', </dev/rhdsk2 > ', </dev/rhdsk3 > ';
Please help me on my doubts above.
Thank you and best regards,
ThereseHi Sunand,
(1) can I add different diskgroup disc even size?. If I add, are there performance problems?
My all data files are out of FRA diskgroup and there are someother diskgroup.A minimum of four (Oracle ASM disks) LUNS of equal size and performance is recommended for each disk group
(2) if FRA diskgroup 50 GB and 100 GB of disks, and then how the archivelog and backup data will be erased?
Data are saved up to 50 GB in all disks of FRA, same 100 GB drive is it?Oracle ASM data distribution policy is based on the ability. Ensure that the Oracle ASM disks in a disk group have the same ability to maintain balance.
(3) while doing recovery with different size of disk at diskgroup, what kind of problems can I face in performance wise?
Ensure that all Oracle ASM disks in a disk group have similar performance characteristics and the availability of storage. In configurations of storage with dimmers of mixed speed, for example, 10 K and 15 K rpm, i/o performance is limited by the slow speed control.
(4) can I remove any diskgroup 50 GB disks and add the 100 GB drive, so that I can increase the size of the disk in the same diskgroup?. I'll remove it and add at the same time.
Yes. First, you add the 100 GB drive and then remove the drives from 50 GB.
(5) to add disks to external redundancy diskgroup, I'm ok with the following query?
ALTER DISKGROUP FRA ADD DRIVE ",", ";Redundancy is controlled by the diskgroup. Then simply add the disks.
e.g ALTER DISKGROUP FRA ADD DISK '/dev/rhdsk1', '/dev/rhdsk2', '/dev/rhdsk3';
See doc below... Here are all your anwser.
http://download.Oracle.com/docs/CD/B19306_01/server.102/b14231/storeman.htm#i1014729
Kind regards
Levi Pereira
http://levipereira.WordPress.com -
I use the outgoing/incoming analog DDK with the DAQ 6341 SMU map.
The examples, for example aoex5, show a single timer (method outTimerHelper::loadUI), but the example shows the DMA loaded with same size of vector data.
There is a comment in the outTimerHelper:call rogramUpdateCount, which implies that memory sizes different pad per channel can be used.
(the comment is: switching between the sizes of the various buffers is not used)
Nobody knows what should be the format the DMA buffer for data from multiple channels with different frequencies?
For example, we want a0 with a sinusoid at 1 kHz and a1 with a sine wave of 1.5 Khz. What looks like the DMA buffer?
With the same frequency for each channel, the data are interleaved, for example (ao0 #0, ao1 #0; ao0 ao1 #1, #1,...), but when the frequencies for each channel is different, what the stamp looks like?
Hello Kenstern,
Data are always intertwined since each card has only a single timing for each subsystem engine.
To AO, you must specify the number of samples that will be released to the AO. You also specify the number of channels. Because he didn't is that a single engine timing for AO, each AO will be channel will be updated at the same time to update clock tick. Data will be interlaced exactly as shown in the example because each channel AO needs output at each tick of the clock to update. The data itself can change depending on the frequency you want to copy.
kenstern wrote:
For example, we want a0 with a sinusoid at 1 kHz and a1 with a sine wave of 1.5 Khz. What looks like the DMA buffer?
With the same frequency for each channel, the data are interleaved, for example (ao0 #0, ao1 #0; ao0 ao1 #1, #1,...), but when the frequencies for each channel is different, what the stamp looks like?
In your example, you must come with an update rate that works for the two waveforms (sine waves of 1 and 1.5 KHz). To get a good representation of a sine wave, you need to update more than 10 x faster than your fastest frequency... I would recommend x 100 if possible.
Update frequency: 150 KHz
Channels: 2
Then create you stamps that include complete cycles of each wave you want to produce based on the frequency of update. These buffers must also be of the same size.
Buffer 1: Contains data for the sine wave of 1 KHz, 300 points 2 cycles of sine wave
Buffer 2: Contains data for the sine wave of 1.5 KHz, 300 points, 3 cycles of sine wave
You can Interleave them as before. When the data are performed through the ADC, they are out different sine waves, even if the AO channels are updated at the same speed.
-
Graph XY overlay multi field with different colors
Hello
I want to make a cyclic XY one track loop and plot the graph for each cycle in different colors.
I want a field like XYgraph2 but with different colors and probably even without this line of tracing. How can I change my schema?
Thank you for your time and your efforts.
KOUYATÉ
Try this.
-
I am trying to replace 15 PCs. They all have XP because their BONES, bought with different SPs at different times. They all have been updated to SP3... They have all MS 2003, upgaded to MS 2007. I would use a clone as image. I do not support different key codes? Although the XP are authentic, I may not all key codes. My predessor has not keep good records, and stickers on some had labels of Vista. Even if the PC was bought with XP downgrade. I need to use XP because of some other software requirements.
What is the best way to represent all the PC so that I can get back them to my users?
Hello
I suggest you to refer to this link and check if it helps:
It will be useful.
Maybe you are looking for
-
driver sp64786 does not work on my hp
Hello I have a problem with my laptop, it is new and did not have drivers on cd, so I look forward in internet and I found that for the hp model 250 g2 driver for the wireless internet is the sp64786. I do the installation but it stops and show a mes
-
xp pro Setup cannot copy modem.sys
Hi you During the installation of Windows XP PRO, he stopped saying DO COPY MODEM. SYS. I can't get the pen. Any help will be appreciated. TKS. Rechiene.
-
Fax guard Console putting a 1 in front of the telephone number when it is NOT needed.
Fax Console won't let me do anything for a large part of my State, AZ, fax because there are two other codes that do NOT require the number 1 in front fo them. The phone recording company said «It is not necessary to dial a 1...» I tried following "
-
Why as I get Install Java games pogo - this happened today and if I reinstall still the same
Today, when I went on Pogo to play games I've had that need to install Java. So I reinstalled and still can not play in Pogo. Just a window to install Java again and again. I am very disappointed by Windows 7 Home Premium.
-
Installed printer HP Photosmart 7520 - Lexmark X 422 driver again does not now - help?
Tried to install the printer as it is wireless and think I must have messed up somewhere! Could not make it work so tried usb but when same could not get to work - finally got wireless installed and now computer says driver, Lexmark X 422, does not