Title Case with Articles in Lowercase

Is there a script or a way to get true Title Case? Illustrator caps every first letter. Seems word does the same, can't believe that there still is not an option for this.

Mike, now it works with
textFrame selection(s)
and textRange selection
what is it what you're having problems with? what other scenarios do you have to work with?

Similar Messages

  • Smart Title Case - problem with script

    Having a problem here.
    When multiple paragraphs are selected the start of a paragraph is set to a lowercase
    how can I fix this?
    //DESCRIPTION: Converts selected text to title case smartly
    var ignoreWords = ["a", "an", "and", "the", "to", "with", "in", "on", "as", "of", "or", "at", "into", "that",
             "by", "from", "their", "then", "for", "are", "not","cannot", "be", "is", "which", "can"];
    var intCaps = ["PineRidge","InDesign","NJ","UMC", "FCCLA", "SkillsUSA", "d’Oeuvres", "VAT", "VIES",];
    // or by creating text files named ignoreWords.txt and intCaps.txt in the same folder as the script
    ignoreWords = getIgnoreFile(ignoreWords);
    intCaps = getIntCaps(intCaps);
    try {
        myText = app.selection[0].texts[0].contents;
    } catch(e) {
        exit();
    theWordRanges = myText.split("/");
    for (var i = theWordRanges.length - 1; i >= 0; i--) {
        theWords = theWordRanges[i].toLowerCase().split(" ");
        //First word must have a cap, but might have an internal cap
        myNewText = "";
        for (var j = 0; theWords.length > j; j++) {
            k = isIn(intCaps,theWords[j])
            if (k > -1) {
                myNewText = myNewText + intCaps[k] + " ";
                continue;
            } else {
                if ((isIn(ignoreWords,theWords[j]) > -1) && (j != 0)) {
                    myNewText = myNewText + theWords[j] + " ";
                } else {
                    myNewText = myNewText + InitCap(theWords[j]) + " ";
        theWordRanges[i] = myNewText.substring(0,myNewText.length - 1)
    app.selection[0].texts[0].contents = theWordRanges.join("/");
    // +++++++ Functions Start Here +++++++++++++++++++++++
    function getIgnoreFile(theWords) {
        var myFile = File(File(getScriptPath()).parent.fsName + "/ignoreWords.txt");
        if (!myFile.exists) { return theWords }
        // File exists, so use it instead
        myFile.open("r");
        var importedWords = myFile.read();
        myFile.close();
        return importedWords.split("\n"); // Could filter these, but what's the point?
    function getIntCaps(theWords) {
        var myFile = File(File(getScriptPath()).parent.fsName + "/intCaps.txt");
        if (!myFile.exists) { return theWords }
        // File exists, so use it instead
        myFile.open("r");
        var importedWords = myFile.read();
        myFile.close();
        return importedWords.split("\n"); // Could filter these, but what's the point?
    function getScriptPath() {
        // This function returns the path to the active script, even when running ESTK
        try {
            return app.activeScript;
        } catch(e) {
            return e.fileName;
    function isIn(aList,aWord) {
        for (var i = 0; aList.length > i; i++) {
            if (aList[i].toLowerCase() == aWord) {
                return i;
        return -1;
    function InitCap(aWord) {
        if (aWord.length == 1) {
            return (aWord.toUpperCase());
        return (aWord.substr(0,1).toUpperCase() + aWord.substring(1,aWord.length))

    Hi,
    Looks like it is a 'paragraph mark' problem which can be seen as 1st char in some strings.
    modify these two lines:
         theWordRanges = myText.split("\r");
         app.selection[0].texts[0].contents = theWordRanges.join("\r");
    Jarek

  • How can I use a script in a Livecycle Designer form, to force display of text in Title Case?

    Hello,
    I am a 'novice' who is DIY'ing the construction of a dynamic pdf form, using Adobe Livecycle Designer 7 (I know, it's a VERY old version!)
    [So, any help that comes along must be 'for Idiots'!]
    I need to construct a code (Java script?) so that a few of my text-fields DISPLAY data in Title Case - IRRESPECTIVE of how the user types in the data.
    So, for example, in a "Address" text-field...
    If someone types in ..
    "205 sherborne avenue"
    - OR -
    "205 Sherborne avenue"
    - OR -
    "205 SHERBORNE AVENUE"...
    I need the data to be DISPLAYED ESSENTIALLY as...
    "205 Sherborne Avenue".
    I found the following code online, and tried it in the 'exit' event of the field I need to modify (with 'language' selected as JavaScript)...
    <   this.rawValue = this.rawValue.replace(/\b([a-z])/g, function (_, initial) {return initial.toUpperCase();});   >
    ... This did convert all the 'initial' letters of the words to Upper Case - AS LONG AS they were not ALL typed in Upper Case!
    So, that code worked for the first two of my samples for Sherborne Avenue above - but it did NOT work for the last one...
    That is, "205 SHERBORNE AVENUE" did NOT get converted to Title Case - which is what I need help with.
    Thanks in advance...

    Hey TundraSteve,
    Thanks a tonne!
    Works perfectly!!!
    In fact, your solution is so elegant and direct, that even I am beginning to get a sense of how it works... I have looked at LOTS of similar codes in the past few days, but was not at all getting a sense of how they are working! But comparing your solution with the earlier one I mentioned, I am beginning to get a sense of things!
    Any suggestions for what I should read-up in order to understand this king of coding?
    I have basically been using the built-in 'Help' - and, trial-and-error - and I have designed my first form - a pretty elaborate one, actually!
    So, it would be great if you could guide me through the 'learning curve' a bit!
    [I have figured-out the 'basics' - that is, I can lay out the form, use 'if-expressions' (FormCalc), trigger events, even build Subforms that are hidden but 'appear' when triggered by other actions, and so on. What I can't figure out are the various 'code languages' (syntax?) that are being used - like " var sometext", for eg.!]
    Cheers, and thanks again!

  • Looking for a simple way to convert a string to title case

    New to LiveCycle and Javascript.  Looking for a simple way to convert a string to title case, except acronyms.  Currently using the the following, it converts acronyms to lower case:
    var str  =  this.rawValue;
    var upCase = str.split(" ");
    for(i=0; i < upCase.length; i++) {
    upCase[i] = upCase[i].substr(0,1).toUpperCase() + upCase[i].substr(1).toLowerCase();
    this.rawValue = upCase.join(' ');

    Thanks for the reply.
    Found the following script in a forum, which works fine as a "custom validation script" in the.pdf version of my form.  However, it will not work in LiveCycle?  The problem seems to be with
    "return str.replace(/[A-Za-z0-9\u00C0-\u00FF]+[^\s-]*/g"
    function toTitleCase(str) {
    var smallWords = /^(a|an|and|as|at|but|by|en|for|if|in|nor|of|on|or|per|the|to|vs?\.?|via)$/i;
        return str.replace(/[A-Za-z0-9\u00C0-\u00FF]+[^\s-]*/g, function(match, index, title){
    if (index > 0 && index + match.length !== title.length &&
      match.search(smallWords) > -1 && title.charAt(index - 2) !== ":" &&
    (title.charAt(index + match.length) !== '-' || title.charAt(index - 1) === '-') &&
    title.charAt(index - 1).search(/[^\s-]/) < 0) {
    return match.toLowerCase();
    if (match.substr(1).search(/[A-Z]|\../) > -1) {
      return match;
      return match.charAt(0).toUpperCase() + match.substr(1);
    event.value = toTitleCase(event.value);

  • Logical Model Naming Standard (Title Case) and Foward ENGINEERING how to???

    Hi,
    I just installed the datamodeler v3.3.0.747.
    I want to use the Title Case style as separator style in my logic Model... To do this, i go to the Preferences Settings (Tools > Preferences > Naming Starndard > Logic Model) and set the Title Case as separator Style...
    However, when i do foward engineering of the logical model... The Style is omitted and everything is like the logical model... For example,
    If i create an entity called: ManagedAccount, i will expected that when i do fwd enginnering, the table associated to that entity will be call as Managed_Account; However, i still getting ManagedAccount...
    So, What am i doing wrong??? or this is a bug???
    Thanks!

    Hi,
    in order to get it working in current release you need to create glossary even empty one and set its property "Incomplete Modifiers" to true (check the check box with that name), and to to add that glossary in "Tools>Preferences>Data Modeler>Naming Standard".
    We'll change it in next release to work without glossary for this particular case.
    Philip

  • Title Case

    Hello,
    I have a table TRANS with a column called NAME (varchar2(40)). Most of the records are in title case already (St. John St) but there are a few in upper case (OLD HIGHWAY). I want to change the upper case records to title case. I've seen a few different ways on the internet to do this but I don't really understand them. I'm using SQLPLUS.
    Any advice is appreciated! Thanks!

    Be warned. INITCAP() is similar to, but not the same as TITLE(). INITCAP() makes the first letter or each word upper case. The function TITLE(), where I have seen it implemented, leaves minor words lower case - as in a book title.
    INITCAP('not a deal') returns Not A Deal. TITLE('not a deal') would return Not a Deal.
    Not necessarily a problem, just be aware of it.

  • Make the Names to appear in title case

    Hi Friends,
    SAP master data maintained with all caps letters in standard & additional fields, but users are asking to make the Names to appear in title case in Ad hoc reports.
    Pls let me know the procedure.
    $ KL Sha

    Hi Manu And Pavani,
    Here i created a new thread SDN memories.
    please discuss in that.
    Ya, i know pavani waste creating new thread but this thread is meant for some other topic so better not to discuss in this.
    Manoj Shakya

  • When I get an i.m on ichat it mixes up the letters with uppercase and lowercase how do I fix that?

    When I get an i.m on ichat it mixes up the letters with uppercase and lowercase how do I fix that?

    Hi,
    Depends.
    Is it some sort of Incoming Override you have or their Outgoing IM Style ?
    Go to the iChat Menu > Preferences > Alerts
    Select Message Received in the top item/Drop down.
    When selected check that the Apple Script option is Not On
    If it is is the AppleScript Selected the Mix Message Case one ?
    This is iChat 5 only (this particular AppleScript)
    If the Buddy has it set against Send Message they Output Mixed Case IMs so it could be from the other end.
    8:37 PM      Saturday; May 7, 2011
    Please, if posting Logs, do not post any Log info after the line "Binary Images for iChat"
     G4/1GhzDual MDD (Leopard 10.5.8)
     MacBookPro 2Gb( 10.6.7)
    , Mac OS X (10.6.7),
    "Limit the Logs to the Bits above Binary Images."  No, Seriously

  • Title Case - is it possible?

    I have a client who wants a lot of content on his web site put into title case (i.e. all caps but with first letter of each word larger). The only way I can think of is to set a larger font size span for the first letter ... I am dreading doing this, it would be soooo fiddly and clunky. There must be way I can define a style, but I haven't been able to find one ... Anybody have an idea of how to do this?
    thanks!

    You can try using a small-caps style along with text-transform:capitalize, e.g.,
    .caps {
         font-variant:small-caps;
         text-transform:capitalize;
    <p>this is a test <span class="caps">of the small caps when used with a capitalize transform</span>. Is it working?</p>

  • Apple now include case with iPod nano...

    Just thought id let you guys know, that Apple have began to include a case with the iPod nano. Its the same slip case as the one with the 5G iPod.
    iLounge Article
    *nathan

    Would you accept someone selling you a watch telling you, after the fact, mind you, that you should buy a cover for watch
    Yes! I would accept the watch. Its not the watch makers fault that the watch scratches, and its certain users human nature to want to protect it.
    Are you saying that all products should be scratch resistant?
    *nathan
    EDIT: Also, Apple did offer a case before a single person got the nano. Jobs himself showed off the nano Tubes at the special event on 9/7. Apple offered a solution to those who thought it necessary.

  • RSS titles repeating with wrong titles

    I haven't seen this one before. On a PBG4, 10.4.4, Safari is showing very wrong titles for RSS articles. By very wrong, it's repeating titles from a completely different site. The title that's repeating is "Adobe announced today the release of a major new image processing and management software program". The source of this was an RSS feed from the Luminous Landscape site, which isn't the problem.
    The problem is this title is showing up in my RSS feeds from all over. For example, my feed listing from <feed://www.mediabistro.com/fishbowldc/rss/> is showing this title for half the items. Same with many other sites. If a do a View Source this is showing in the source code for these sites. Really.
    Somewhere there's obviously an RSS cache that's screwed up.
    I've used YASU to clear the browser history and all sorts of other items.
    Any idea where this could all be located?

    yup, I've seen this and the fix I use is to render. AND, sometimes if I export a selfcontained qt and the title is not rendered prior to export, it jumps in the exported qt. And this happens in other formats besides ProRes. Don't know what causes it, and rather than spending alot of time on the issue, I have just dealt with it by rendering. Please post if you find the cause.

  • IDCS Title Case Paragraph Style

    Hi, I'm trying to create a paragraph style That Uses Title Case but my only choices are "Normal", "Small Caps", "All Caps", or "Open Type All Small Caps". I see "Title Case" under the menu: Type > Change Case but not in the paragraph or characters styles dialog box. Any Help Would Be Fantastic. Thanks!

    My Running Headers plug-in has smart title case which gets its words
    based on two different user definable lists: One for lowercase words
    (unless they are at the start or different because of one of the other
    rules...) and another for acronyms and the like (they are always
    capitalized exactly as they appear in the list independent of position).
    InDesign can't even spell its own name! ;)
    I hope to add the smart title case to my Formatting Tools as well. (If
    there's enough interest, I'll probably do it sooner rather than later...) :)
    Dominic that's an excellent point about acronyms which are also words --
    one I hadn't thought about. I believe those can be identified by some
    kind of formatting attribute...
    Harbs

  • Title Case iWork Numbers

    I have a spreadsheet that contains several columns of text which are all uppercase. I would like to format the text so that it has a capital first letter, and the subsequent letters are lower case for that word. The "Title" case which is found in Format>Font>Capitalization>Title Case only seems to work if the text is all lower case. I can't get it to work on any other types of formatted text. Any thoughts on how I can do this? Thanks

    I use an AppleScript to change to title case in Pages. This is based on an old AppleWorks script that I've modified for Pages. Copy & paste your table from Numbers to a blank Pages document then open AppleScript Editor (in Utilities) & paste the following code in a new window & save as a script. You can then run it to convert the text & then copy & paste back to Numbers.
    Give me a couple of days & I'll see if I can make it work in Numbers.
    property lowerOnlyWords : {"a", "an", "the", "and", "of", "for", "from", "in", "on", "before", "after", "between", "behind", "with", "without", "to", "through", "against", "is"}
    property upperChars : "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
    property lowerChars : "abcdefghijklmnopqrstuvwxyz"
    tell application "Pages"
              try
                        set selectionFail to (count each document) < 1 or class of selection is not text
              on error
                        set selectionFail to true
              end try
              if selectionFail then
                        display dialog "You must select some text in a word processing document before running this script."
              else
                        set theText to selection
                        set theWords to {} & every word in theText
                        set wordCount to count theWords
                        set isFirstWord to true
                        repeat with wordN from 1 to wordCount
                                  set oldWord to word wordN in theText
                                  set doLowerOnly to oldWord is in lowerOnlyWords and not isFirstWord
                                  if doLowerOnly then
                                            set startLowerN to 1
                                  else
                                            set startLowerN to 2
                                            set oldCharacter to character 1 in oldWord
                                            set alphaN to offset of oldCharacter in lowerChars
                                            if alphaN > 0 then
                                                      set character 1 in word wordN in theText to character alphaN in upperChars
                                            end if
                                  end if
                                  repeat with charN from startLowerN to length of oldWord
                                            set oldCharacter to character charN in oldWord
                                            set alphaN to offset of oldCharacter in upperChars
                                            if alphaN > 0 then
                                                      set character charN in word wordN in theText to character alphaN in lowerChars
                                            end if
                                  end repeat
                                  set isFirstWord to false
                        end repeat
      select theText
              end if
    end tell

  • IPod nano case with protective screen, available in store (looking for one)

    Hey, im looking forward to buy my first mp3 player, and its gonna be a white iPod Nano. I read alot of reviews, and some people have problems with scratches, and their screen cracking. I am really concerned about the screen cracking.
    Is there a good quality protective case with a screen protector, (maybe a wheel protecter, not noccesary though), that is sold at major stores (wal-mart, circuit city, bestbuy, etc)? Price can be an issue too, so not too expensive. Thanks in advance!
    pc   Windows XP  

    http://www.walmart.com/catalog/product.do?product_id=4328727
    would this be a good case?

  • Will Tablet case with combined keyboard work on Lenovo Ideapad A1 07

    Hi All,
    Sorry if anyone has asked before but couldn't find specific.
    My wife has recently purchased a Lenovo Ideapad A1 07 for its size,  a friend who has a small android tablet also recommended to her, to buy a tablet case with combined keyboard with USB connection from amazon. When received the connection obviously doesn't fit, so I started searching around web for an adapter for it, but I’m seeing conflicting info that the ideapad either does/doesn't support USB data transfer connection point, so before buying an adapter what is correct!.
    Can anyone throw some light onto whether Lenovo will update the firmware to be able to use USB at any time or has anyone have a work around. Any help and advice to get this keyboard working would be grateful as the tablet is a great little device for her.
    Gazzataf  

    If you are patient, go through the reviews of a specific USB keyboard that was suggested as an addition for Lenovo A1 by Amazon: You will see that even though users have tried different cables and adapters, no A1 user has managed to get this working on his tablet.
    This issue may be solved by a future upgrade (if any), which will enable the USB OTG feature of the microUSB port of the A1 tablet. Until then, nothing can be done in order to have any USB device identified and working with A1. I really hope that I make a mistake here and that someone will come up with a working soultion for this issue ...

Maybe you are looking for

  • Duplicating purchased music on two computers?

    I use two computers and sometimes I purchase music from the iTunes Store using one or the other. But, the music I purchased on one computer doesn't show up on the other computer and visa a versa. Is there a method of showing all the music I've purcha

  • Crop operation not working in JAI 1.1.3?

    The "crop" operation seems to be broken in JAI 1.1.3 (at least for Windows): When cropping an image, the values for x and y are ignored and the new image is always the part from the upper left corner of the original image. In JAI 1.1.2 this worked co

  • Blaster WEBCAM GO

    When i wanted install the Webcan GO into my new OS Windows XP-SP2 i'dont install because de program instalation said: "Only for Windows 98". Answer: Exist driver or any way for install this camera in this Os Windows XP-SP2 ? Tanks Ramon my e-mail: [e

  • How do I track my stolen mac?

    My macbook was stolen at the airport. Is there any way that I can track it and get it back?

  • Transfer transactions from Vendor Account A to Vendor Account B

    Hi Gurus, Can you advise is there a standard program or transaction within SAP to transfer items from one vendor account to another vendor account? We need to be able to transfer the detailed account line items. Thanks for any guidance offered. Regar