Script to align the base line of the text downwards containing the model of the?

Hello

I'm curious to know if anyone out there know how to make the button 'Align Vertical from bottom' means when the Panel 'Align' is set to 'Composition' script mode.  Please see the attached screenshot for the button I want to speak--is the one that is highlighted on the right:

Screen Shot 2012-09-12 at 10.31.38 PM.png

Essentially, it clings to the base of the layer selected to the bottom of the receptor composition.  Is this possible to do with scripting?  Any help is appreciated!

Thank you

Laz

This should give you the idea:

{

var app.project.activeItem = myComp;

myLayer = myComp.selectedLayers var [0];

var myRect = myLayer.sourceRectAtTime(0,false);

var myPos = myLayer.property("Position").value;

myY myPos = var [1] + myRect.top + myRect.height;

var myComp.height = deltaY - myY.

myLayer.property("Position").setValue (myPos + [deltaY, 0]);

}

Dan

Tags: After Effects

Similar Questions

  • How to set the text to align with their base line, not their bounding box?

    Untitled.png

    Left: ' vertical align text to bottom'ed with black outline box

    Right: manually move the text with a smart guide to align with its base line. (what I want to achieve)

    As you can see in the left, text has its baseline under him, and his rectangle encompassing does not correspond to its base line. When I use align, it does not align with its base line but his rectangle encompassing.

    How can I make the text line up easily using their base line?

    You can actually get align text, but the method to make some features using the majority of people do not know:

    1. Select type > effect > path > describe the object
    2. in the preferences to put a brake on the front of the preview limits use

  • By aligning the lines in InDesign CS5 colomns

    I have trouble getting lines to align everything using several columns. I tried to align to a baseline alignment and fastening to the frame and have had no success. I tried these links (adobe how - to suggested) but not able to understand this. It is a publication of more than 12 pages, I hope that I am not too complicate it.

    Example:

    Screen Shot 2016-08-18 at 2.03.58 PM.png

    Example of alignment of base:

    Screen Shot 2016-08-18 at 2.19.03 PM.png

    Here is an error:

    Change the start at zero relative to the top margin, not zero relative to the top of the page.

    (The other method is to find your top margin, such as 6P3 and tell 6P3 to the top of the page.)

    Confirm that your leader is of 14.4 or 28.8, etc.

    If spacing is 14.5, the line will jump the following grid.

    Confirm that you have enabled to Use base Grid (preferably with Styles).

    After that, we'll see what happens!

    As Peter said, confirm that the vertical Justification is Top (not justified) to object > text frame Options.

    And just because it is causing so much trouble, confirm that executives do not have a custom reference grid that replaces the reference to the document grid.

  • By aligning the lines between pages in InDesign CS5

    Hi all

    After many fruitless hours of Googling, I'm really, really hoping to find help here with a small matter of InDesign CS5 I'll have. I'll try and keep this brief.

    I am designing a book in InDesign CS5, which has chapters that run one after the other. Considering that in most of the books, a new chapter will start on a new page, here they flow together. For each chapter title, I use a font called: Orial, size 18. For the main text, I use Adobe Garamond Pro, size 12. When I have two solid pages of 12-point Adobe Garamond Pro, all right. The alignment of the lines on the two pages are level with one another. It's just what I want.

    However, if I have a double page and a page has a title Orial 18pt (in all the Adobe Garamond Pro 12pt), that things get mean, as you can see in the image below:

    hdkhfkdhfkhskf.jpg

    As you can see, the lines on page 79 are not leveled with those on page 78. Is there a way to get around this?

    Thanks much for any help you can offer. I'm rather tear my hair out here!

    I'm rather new to InDesign (as is clearly obvious, I know)

    In fact, it was not obvious in your first posting - it is now, but it does explain why you turn on the grid and immediately exclaim that it was exactly what you wanted.

    Skip steps a lot (making the paragraph styles, for example) but at least that, you should get started:

    1) turn on all the stuff the view so you can see what you're doing:

    View-> display-> Normal Mode

    View-> options-> the contours of the block see the

    View-> grid-> see the baseline grid

    2) turn on snap-to-base-grid on all text

    It's easy if you used paragraph styles. It's also easy if your entire book is a long story with connected text frames. If, when you use the text selection cursor, you can press Control-A (or Edit-> Select all) and select all of your text, you can simply click here:

    (3) to set the height of your desired grid (it's in the preferences)

    Now, if each image on each page is controlled by itself (not related to previous and subsequent frames), you can just replace it in the paragraph Style, under "spacing of dashes &." If your images are not linked, and you do not use a paragraph style, you need to select it all the & turn snap to grid on for each page in your document.

    So this should align each line in your doc to the grid. If this does not happen, after what happens, and we're going to understand what is happening.

  • The Bookmark Script list align Page numbers on the right

    Hello

    I have a script that lists the names of bookmark, and then the Page number after the bookmark as follows:

    Bill Smith #1

    Jeffrey Jones Page #5

    Christopher James Page #8

    What I would like the script to achieve is to list the bookmarks and then align Page numbers to the right of the pdf instead of mixed together.

    Please can someone tell if it is possible to do it in javascript?

    The existing code is as follows:

    / * All bookmarks in the list * /.
    / * Work recursive l‟arbre bookmark * /.
    function PrintBookmarks (bm, nLevel)
    {
    If (nLevel! = 0) {/ / do not print the root}
    bmReport.absIndent = bmTab *(nLevel-1);
    BM. Execute();
    bmReport.writeText ("" + bm.name + "Page"+ (bm.doc.pageNum + 1) ");

    }
    If (bm.children! = null)
    for (var i = 0; i < bm.children.length; i ++)
    PrintBookmarks (bm.children [i], nLevel + 1);
    }
    bmTab = 20;
    bmReport = new Report();
    bmReport.size = 2;
    bmReport.writeText (this.title);
    bmReport.writeText("");
    bmReport.size = 1.5;
    bmReport.writeText ("list bookmarks");
    bmReport.writeText("");
    bmReport.size = 1;
    PrintBookmarks (this.bookmarkRoot, 0);
    global.bmRep = bmReport;  do global
    global.wrtDoc = app.setInterval)
    "Try {'} '.
    +' reportDoc = global.bmRep.open ("list bookmarks"); "
    "+' console.println ("open Executed");"
    + "app.clearInterval (global.wrtDoc);"
    +' delete global.wrtDoc;'
    "+' console.println ("App.clearInterval Executed");"
    + "reportDoc.info.title = 'Bookmarks lists';"
    + "reportDoc.info.Author ="Bookmark Sequence list";"
    {+'} catch (e) {console.println ("Meanwhile...:" + e) ";}"}
    (100);

    Any help will be much appreciated

    The purpose of the report is seriously flawed. Beside the known bug page break in version 9 there are many other issues, such as the issue of alignment.

    The best solution I found that it was to place the page numbers on a new line then align them with dash and raise.

  • Y at - it somewhere I can find a list of items that is supposed to be running in activity monitor and those that should raise red flags?  I know the list varies depending on the applications and installed process but a base line would be nice

    Y at - it somewhere that I can find a list of explanations or definitions of applications that are running in the monitor of activity as well as a list of items that should raise red flags?  I realize account from the list will vary depending on the applications and programs installed and running, but it would be nice to have a base line of what should be expected and considered safe or normal.  There are too many items to research and one at a time.

    No, not so much.

    You have a problem you're trying to solve?

  • Upgrade Express on 7, that an error has occurred in the script on this page. Line 0. Char from 0. Script error. code 0. "with a URL

    Hello

    After looking on any 3rd party retailers appear Anytime Upgrade key for 7 to professional.

    When I try Anytime Upgrade system that is integrated and use 'go online to choose Windows7 edition which is best', an error box comes in reading "an error has occurred in the script on this page. Line 0. Char from 0. Script error. code 0. "with a URL.

    When I try the store I find nothing either. Can I deduce that Microsoft no longer sell upgrades between versions of windows 7?

    Whenever upgrades have long past gone

    Finally unless you are interested in win-10 which is.

    Many win-7 pro autour on Newegg and Amazon, but they are not at level only oem / system integrator.

    You could buy one and a new ssd / HDD to install on and use the original win-7 to move to 10 - win

    Then passed to win-10 pro for 99.us.

  • HP Envy 110 Series printers and I tried several times to reprint documents m in different qualities and align the cartridges, but the lines of words have dragged through them

    I have a HP Envy 110 series printers and I tried several times to reprint documents m in different qualities and align the cartridges, but the lines of words have dragged through them and are not clear. Much of the document is blurry and cut through. Any suggestions?

    Read this article, he describes some steps on how to use the printer utility that came with the printer to run a few steps that might improve the print quality, including cleaning the print cartridge and other procedures.

  • Keep the text perpendicular to the base line when you use the string.

    Is there a way to keep the text perpendicular to the base line when using the warp function?  I'm trying to reproduce a decal with curved text.  When I use the string to get the text that is curved like the original, the letters are slightly tilted.

    You could try to make each letter on a separate text layer, then use Image > transform > free transform to adapt the letters in place.

    A lot more control over the placement of the letter and size that warp text offers.

  • Basic conditional script based on the number of lines in a text layer?

    Just received help here to write a conditional script by using the font size of a text layer. Thank you all for this.

    The next hurdle is a conditional script using the number of lines in a text layer in the differential. Far as I can tell it not the layer details which specify the number of lines. Just '\r' for a return in the idTxt descriptor. Nothing seems to stand for a soft return as far as I can tell. I'll probably have to be able to count the lines with soft and hard returns.

    Any thoughts?

    I was playing around with this a bit and here is a small script to determine the number of rows. This is based on the self in the head, that I calculated to environ.108 times the size of the font.

    #target photoshop
    app.preferences.rulerUnits = Units.POINTS;
    var doc = activeDocument
    var tL = doc.activeLayer
    var h = tL.bounds[3]-tL.bounds[1]
    var per = ((h/5)-(tL.textItem.size))/tL.textItem.size
    var num = h/(tL.textItem.size *1.108)
    
    alert(Math.round( num))
    
  • Help with a script that detects the content in a cell and apply the cell style to line

    Hello


    I am trying to add an article to my table formatting script that is a cell with the word 'Budget' (but this can be written as ' Budget:' or ' Budget: (E) "- but without the speech marks) and apply the cell Style - SponsorCells - to all the cells of the whole line. I currently have on what it will, but it does not work:


    function checkWhichTable()
    {
    // ensure the user made a selection
    if (app.selection.length != 1)
    return null;
    var currentTable = app.selection[0];
    if (currentTable.hasOwnProperty("baseline"))
    {
    currentTable = app.selection[0].parent;
    }
    while (currentTable instanceof Cell || currentTable instanceof Row || currentTable instanceof Column)
    currentTable = currentTable.parent;
    if (!(currentTable instanceof Table))
    {
    // No table selected
    return null;
    }
    return currentTable;
    }
    app.doScript(checkUserSelection, ScriptLanguage.JAVASCRIPT, undefined, UndoModes.ENTIRE_SCRIPT, "Process Table");
    
    
    function checkUserSelection ()
    {
    var a_table = checkWhichTable();
    if (a_table == null)
    {
    if (confirm("No table selected. Do you want to process *all* tables?") == false)
    return;
    allTables = app.activeDocument.stories.everyItem().tables.everyItem().getElements();
    for (aTable=0; aTable<allTables.length; aTable++)
    {
    processTable (allTables[aTable]);
    }
    } else
    {
    processTable (a_table);
    }
    }
    function processTable(table)
    {
    // do something here!
    
    
    //Set 1st Row Height
    table.rows[0].height = "30mm";
    
    
    //Find Text in Cell and apply Cell Style to Row 
    var  
      myCellText=['Budget', 'Budget:', 'Budget: (E)'];  
     var myRegEx = new RegExp("^("+myCellText.join("|")+")$");
      for (i=0; i<table.cells.length; i++)
      {
        if (table.cells[i].texts[0].contents.match(myRegEx))
          table.cell[i].appliedCellStyle = "SponsorCells";
      }
    
    
    //end - do something here!
    }  
    


    I can get the script to apply the cell style to "SponsorCells" for each cell that contain the word 'Budget' etc, but I need cell ever on this line to have the cell style applied. I tried to re-write line 56 which applies the style to a cell, but I can't seem to make it work. Any help would be great.


    Separate on this issue, I would like to have a line of code similar to the 46 line, which sets the 1st height of lines, but I would like to say "If a cell has 'A cell Style' and then applies the value height 10 mm". If someone could result as a help of bonuses, things would be great double.


    Thanks in advance!

    But that could be painfully slow. To speed things up, follow these steps:

    var cells = table.cells.everyItem().getElements();
    for (var i=0; i
    

    It is faster, because it creates an array of cells with a call to table.cells, which is several times faster than calling table.cells. And before assigning to line 12mm height is useful to check if it is already 12 mm. checking things in InDesign and do things only when it is necessary is much more effective than simply doing things even if they are not necessary.

  • Align the text with multiple lines

    Hi, I need help fast please. I thought it would be easy, but I can't get out and hours of searching online turned up nothing. Sorry if this is posted in the wrong place!

    I need align the text on several lines. It's a calendar I design for charity. I'm stuck with letters and numbers. The requested provision is a little like this...

    M T W Th F S S

    1 2 3 4 5 6 7

    I need the numbers to be central at the time, if that makes sense? The only way I could do it so far is to write in excel, Center it and then paste it to the Commission in the PS, but due to the size, I work at, I have to resize each month individually, which means they could end up being slightly different and I need them to be perfect. Is it possible that I can do this in PS, I know, I work with the exact sizes on each month?

    It's probably something really simple that I'm missing, but I just can't cope.

    I use CS6 and the font is Century Gothic, if that's any help.

    Thanks in advance!

    I've now sorted! Thanks anyway

  • A script to apply the style of cell to whole lines containing specific text

    Hello

    I use InDesign CC 2014

    Does anyone know how apply a cellstyle based on the content of text found in a cell in javascript?

    I need to find the document and change cell style in the entire line to 'cellStyle01' If the 'etc' text appears in the cell.

    I found a similar script here to the forum which apply the table style, but do not know how to change it to apply the cell style!

    var curDoc = app.activeDocument;
    var allTables = curDoc.stories.everyItem().tables.everyItem();
      
    app.findTextPreferences = app.changeTextPreferences = null;
    app.findTextPreferences.findWhat = "someText";
    var allFounds = allTables.findText();
    app.findTextPreferences = app.changeTextPreferences = null;
      
    for ( var i = 0; i < allFounds.length; i++ ) {
    var curFound = allFounds[i];
    if ( curFound.length == 1 ) {
    var curFoundParent = curFound[0].parent;  
    // curFoundParent.parent.appliedTableStyle = curDoc.tableStyles.itemByName( "tableStyle" );  
    curFoundParent.parent.appliedCellStyle = curDoc.cellStyles.itemByName("cellStyle01");  
    }
    }
    
    

    Thank you!

    Hello

    in this new case, you can't just change the last line, because yo I want to find not the entire table and lines and cells.

    Try this modified version:

    var curDoc = app.activeDocument;
    var allTables = curDoc.stories.everyItem().tables.everyItem(); 
    
    app.findTextPreferences = app.changeTextPreferences = null;
    app.findTextPreferences.findWhat = "some Text";
    var allFounds = allTables.findText();
    app.findTextPreferences = app.changeTextPreferences = null;
    
    for ( var i = 0; i < allFounds.length; i++ ) {
        var tableFound = allFounds[i];
        if ( tableFound.length > 0 ) {
            for ( var j = 0; j < tableFound.length; j++ ) {
                var curFound = tableFound[j];
                var cellsInRow = curFound.parent.parentRow.cells.everyItem();
                cellsInRow.appliedCellStyle = curDoc.cellStyles.itemByName( "cellStyle01" );
                cellsInRow.clearCellStyleOverrides( true );
            } // end for
        } // end if
    } // end for
    
  • VM upgrade with Update Manager - how to tie yourself to the base line of tools

    I'm upgrading from the tools of Virtual Machines on one of our servers ESX - ESX8.

    There are several virtual machines (10-20). I tried to reach the default baseline provided with vSphere (VMware Tools upgrade to Match) on the ESX Server and the VMware tools to upgrade, to Match database does not appear.

    The vShpere update #2 video series shows the user using a folder it created in the virtual machine and discovers patterns with all virtual machines of Xp in a folder.

    He joined upgrade VMware tools to Match base and scans and corrects all Xps.

    If I go to the virtual machine and view models and I see short folder Vms, VMs, templates, etc.

    But the associated virtual machines seem to be in alphabetical order and not in an order that associates them with ESX8.

    If I create a folder under the folder open VMs and try to move the virtual machines associated with ESX8 in the folder, it does not work.

    I even tried to create a new database and tried to add to the game, but always VMware tools upgrade not can link it to the host.

    Is there a way to get the Update Manager to work at the level of the host with the host ESX8, so I can join VMware Tools upgrade ESX8 game database and update tools?

    Otherwise, the update of all virtual machines manually by connecting the base to each line take very long.

    Thank you

    Create your custom (depending on model and VM) folder, move the virtual machine and fix the base line here.

    André

  • Reset the base line

    Update baseline

    Hello!!
    I need to set the base line according to the actual dates, I mean, the 'new' base line must be equal to the current schedule. For activities that even 0% line base is equal to current; But if there activities actual date, I can't give themselves to the base line columns as the current. What can I do to have the dates of the base line as my current Date (current date updated dec, 10-2010). It was decided: the update of December will become the new base line. Sorry the bad English. Thanks to you all! Ricardo, from the Brazil.

    Ricardo

    You can set this by going to the value tab won of preferences ADMIN - ADMIN then won the calculation of the value you must select "joined to the budget of values with the current dates.

Maybe you are looking for

  • Fireforx 38.0.5 has no scroll bar

    This happened only since I updated the browser. If I click on a link and it will open in a new window, the new window has no display of the scrollbar or toolbar. I looked at various "topic: config ' resolutions, but I'm not a programmer and I was won

  • Need drivers of Windows XP Home for Satellite L40 - 13G

    I need audio drivers for windows XP for satellite L40 - 13G? I try to download it from the site intel and Analog Devices Web site, but it does not work. P.S. sorry - but my English is not very well ;-)

  • My k1 is dead

    My k1 did not start this morning. I put him to sleep last night after reading the PDF, this morning, I tried to click on the power button to wake up, but nothing happened, the display lights, so I press the power button, tried to stop (or restart), a

  • p pilot 8470 EliteBook

    I had to re - install Windows 7 Pro (64 bit) after a virus attack but could not connect to wireless internet since.  The laptop works when the cable is connected to the broadband router, but not when the cable is disconnected.  The laptop says that I

  • Clip plus 8 GB capacity as is 7.37 GB normal?

    Is it normal to have only 7.37 GB total capacity on my new Clip + 8 GB version? My old 8 GB 2nd gen capacity Clip is slightly larger, a few hundred MB larger. Can someone delete this?