Text object, 2 font styles

Text Object ,
ONE text object, 2 fonts styles?
(Q1) Is possible to handle this styles:
[Text1]
String: [Arial Font and Courier New Font]
(Q2) If can handle, in Formula, can do it this effect ?
Please!

Hello Looploop,
You won't be able to do this within a single text object but it can be done in a formula if you use HTML text. In the formula surround the string you want to display in Arial with HTML tags for arial font and the other portion of the string in HTML tags that output courier font. After you have placed the formula on the report right click on it > Format Field > Paragraph tab and select HTML Text for Text Interpretation.

Similar Messages

  • Printing html text and font styles

    Hello,
    when I try to print html text in serif with italic or bold text style the output on a printer incorrectly shows the bold and italic parts in arial or something. Underlined text is printed correctly.
    The font is rendered correctly on a JEditorPane.
    There were some issues with html rendering in java (e.g. Bug IDs 4331766, 4160605, 1235430, 4141537) but as these bugs are closed/fixed in earlier jdk versions, and i found no hint that anyone else has experienced such problems, i may be doing something wrong?
    Regards,
    Dirk
    My Configuration: Windows 2000 (German), JDK 1.5.0_12
    For testing purposes i use the following:
    import java.awt.BorderLayout;
    import java.awt.Dimension;
    import java.awt.Graphics;
    import java.awt.Graphics2D;
    import java.awt.event.WindowAdapter;
    import java.awt.event.WindowEvent;
    import java.awt.print.PageFormat;
    import java.awt.print.Printable;
    import java.awt.print.PrinterException;
    import java.awt.print.PrinterJob;
    import java.io.ByteArrayInputStream;
    import java.io.IOException;
    import javax.swing.JEditorPane;
    import javax.swing.JFrame;
    import javax.swing.RepaintManager;
    import javax.swing.text.BadLocationException;
    import javax.swing.text.Document;
    import javax.swing.text.html.HTMLEditorKit;
    * QDH (Quick and Dirty Hack) Test
    public class PrintTestPane extends JEditorPane implements Printable {
       * shows printDialog and starts printing
      private void print() {
        PrinterJob job = PrinterJob.getPrinterJob();
        job.setPrintable( this );
        if ( job.printDialog() ) {
          try {
            job.print();
          catch ( Exception ex ) {
            ex.printStackTrace();
        else {
          System.out.println( "Aborted" );
       * from Printable Interface: renders a page
      public int print( Graphics graphics, PageFormat pageFormat, int pageIndex )
          throws PrinterException {
        Graphics2D g2 = (Graphics2D) graphics;
        RepaintManager.currentManager( this ).setDoubleBufferingEnabled( false );
        Dimension d = getSize();
        double panelWidth = d.width;
        double panelHeight = d.height;
        double pageWidth = pageFormat.getImageableWidth();
        double pageHeight = pageFormat.getImageableHeight();
        double scale = pageWidth / panelWidth;
        int totalNumPages = (int) Math.ceil( scale * panelHeight / pageHeight );
        // Check for empty pages
        if ( pageIndex >= totalNumPages )
          return Printable.NO_SUCH_PAGE;
        g2.translate( pageFormat.getImageableX(), pageFormat.getImageableY() );
        g2.translate( 0f, -pageIndex * pageHeight );
        g2.scale( scale, scale );
        print( g2 );
        return Printable.PAGE_EXISTS;
       * @param args
      public static void main( String[] args ) {
        PrintTestPane testPane = new PrintTestPane();
        HTMLEditorKit kit = new HTMLEditorKit();
        Document doc = kit.createDefaultDocument();
        try {
          kit.read( new ByteArrayInputStream( htmltext.getBytes() ), doc, 0 );
        catch ( IOException e ) {
          throw new RuntimeException( e );
        catch ( BadLocationException e ) {
          throw new RuntimeException( e );
        testPane.setContentType( "text/html" );
        testPane.setDocument( doc );
        JFrame frame = new JFrame();
        frame.getContentPane().add( testPane, BorderLayout.CENTER );
        frame.addWindowListener( new WindowAdapter() {
          public void windowClosing( WindowEvent event ) {
            System.exit( 0 );
        frame.pack();
        frame.setVisible( true );
        testPane.print();
      private static String htmltext = " <html> <head>  </head>  <body> <font face=\"serif\"> plain <b>bold</b> plain <i>italic</i> plain <u>underlined</u> plain</font> </body> </html>";
      private static final long serialVersionUID = 1L;
    }

    Hello again,
    Update:
    With JRE 6 it seems to work (at least with update 2). Because Java 6 is currently not an option for me: should i file a Bug?
    Dirk

  • Text1 object, font is use x+2

    Modifying a text object.
    Using Format Painter to change font styles.
    dynamic font styles
    Format Editor
    :Font:
    Font: Arial x+2
    http://www.scientificcomputing.com/images/0602/sc62OLS_fig1_lrg.jpg
    Now, would you mind to tell me,
    In
    Format Editor
    :Font:
    Font: Arial x+2
    click x+2
    formula. font name
    enter this code, but no success work?
    this code is check that filed (string) is "Chinese" string or "english" string
    if is "chinese" string, return Text1.Text object, Font is use "Arial"
    else
    is "english" string, return Text1.Text Object , Font is use  "Bookman Old Style"
    Please!
    stringvar x := {JOSX.T_SOURCE};
    stringvar y := '';
    numbervar i;
    for i := 1 to length(x) do
    if asc(x<i>) > 128 then
    //y := "non-english name. chinese name, japan name. " & x;
    "Arial"
    i := length(x) + 2;
    exit for;
    if i = length(x) + 1 then
    //y := "english name. " & x;
    "Bookman Old Style"
    //y;

    Try changing it to:
    stringvar x := {JOSX.T_SOURCE};
    numbervar i;
    numbervar t;
    t := 0;
    for i := 1 to length(x) do
    if asc(x<i>) > 128 then
    t := 1;
    exit for;
    if t = 1 then
    "Arial"
    ) else (
    "Bookman Old Style"
    HTH,
    Carl

  • Can I embed fonts of all Dynamic Text objects in a Flash file?

    Hi there!
    I'm fairly new to Flash, so please bear with me.
    I have created a Flash file which will act as our company's standard presentation / portfolio of all previous projects.  I've pretty much got it running the way I want, but I've just tried it on a few different computers and realised that the fonts aren't embedded.  I've used our corporate font so it needs to look right.  Having read the following documentation (http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=Liv eDocs_Parts&file=00000893.html) I now understand how to embed fonts for one dynamic text object at a time.  However, I have a lot of different dynamic text objects in the file and I would dearly love to embed them all in one step!  The same embedding options can be applied to just about all objects, as they're all the same size and font.
    I hope someone can help me.  If you are able to help please spell things out in simple steps!!  I am aware that I probably haven't yet grasped a number of the basics of Flash.
    Thanks in advance,
    Stuart

    Static text doesn't need to be embeded. So I'm not sure what the problem you are having is. The page you linked to is for making an embedded font in your library that can then be exported for actionscript and used by code and style sheets. If you are following the instructions on the page you liked to you only need to do that once. Which shouldn't be too hard.
    That is usually a different problem that having a bunch of different authortime created textfields that need to have characters embedded.
    As far as I know your only hope to change a bunch of authortime/library items is using JSFL. So even if the thing I pointed to isn't exactly what you need you could keep googling a bit or use that as a template.
    JSFL files are just text files so open it in note pad. Look for the line:
    if(it[i].itemType == "movie clip")
    and change it to this:
    if(it[i].itemType == "movie clip" || it[i].itemType=="button")
    Now it does buttons. You give up too easy.

  • How to use different font styles in the same boolean text?

    Hi all,
    As reported here http://digital.ni.com/public.nsf/allkb/6BD344ACA4DEE20A8625692700737E16, it is possible to change font color, size or other font properties of a subtext in a string indicator. This can be applied to a caption too.
    I'd like to apply this properties to a boolean text but it does not work. The boolean control has the Text.selectionStart and End property node but it does not appear to function.
    Can you help me?
    Thanks all

    This is a bug in the development environment (I think it showed up around LV8).
    There's a workaround, but it seems to work intermittently: Place some floating text on your front panel, then edit it's font styles.  Select and copy the floating text.  Select the boolean text (double click on it).  Paste.

  • Does anyone know how to select text in Appleworks, click on the font button and then be able to scroll thru all the font so that one can see the text change as you scroll down the list, at present  I have to do it one font style at a time and then repeat

    does anyone know how to view text in Appleworks, to be able to click on the font button and then be able to scroll thru all the font so that one can see it change as you scroll down the list, at present  I have to do it one font style at a time and then repeat? Thanks jl

    Welcome to the Apple forums
    Your question really belongs in the AppleWorks community/forum.
    You can turn on fonts in actual type in the AppleWorks preferences.

  • End user have ability to change font style in text field of interactive pdf form?

    Does the end user of an interactive pdf form able to change the font style, i.e.: make something bold or underline a word in a text field?
    I am making a form with text fields and the end user would like the ability to make something bold or underline it.. I do not see anywhere in acrobat that allows styles to be changed.
    I have created the form in Indesign > saved it as an interactive pdf and brought it into Acrobat.

    Thank you for the quick response! Do you set this in Indesign before exporting or do you set this in Acrobat? I am in Acrobat 10.1.10 and when I go to properties it doesn't give me  'options' to choose from.

  • Apply different font styles in single text frame

    hi all
    how can i apply different font styles in a single text frame using indesign script ?
    for example :
    "dasdnasndasndlasndnasdlasdasdas"
    may i know is it possible to do that and how to do that ?
    thanks

    You can set (as well as read) every single property of any text range with scripts. This is javascript; it assumes you text cursor is inside a frame with some text.
    * Setting some specific characters to a color:
    app.selection[0].parentStory.characters.itemByRange(5,10).fillColor = "Red";
    * Change the font of words:
    app.selection[0].parentStory.words[3].appliedFont = "Arial\tBold";
    * .. or just the style:
    app.selection[0].parentStory.lines[2].fontStyle = "Italic";
    * .. or any other attribute (this one requires you to have at least 5 characters selected):
    app.selection[0].characters[5].underline = true;
    Of course these operations are not limited to something you select; they work the same with any text frames you can refer to.
    app.activeDocument.textFrames[1].paragraphs[2].appliedCharacterStyle = "charstyle";

  • Change the font typeface of text object in form Master Page

    Dear all,
            I am creating a Adobe Livecycle form with multi-language support. Simply, there is a header title that is a text object in master page. I want that it can be converted to simplified Chinese from English and change its font typeface to “SimSun” when printing begins. I try the following code on its “Initize” event to do this.
    Simply, I configure a print flag(Y/N) in form so that it will convert into simplified Chinese and change the font typeface to ‘SimSun’ when the flag is reset to ‘Y’.
    Int langInt = i ;       
    If (pFlag  == “Y”) {
               PaymentRequisitionApp.pageSet.Page1.MasterSubform. Text1.value.text.value = l_XML.Record[i].TITLE.toString();
               PaymentRequisitionApp.pageSet.Page1.MasterSubform. Text1.font.typeface ="simsun";
    I found that it doesn’t work. There is something else in the form to reset the title to English. So I try to paste the code above in “calculate” event of tex1 object. It’s work!
    Question:
    1.      Anyone can tell me that the implement order of the events in the form?
    2.      Does it exist other better way to do this?
            3.  Which event, function or any else let the master page’s object to be reset?

    this link for downloading the sample is valid:
    http://rapidshare.com/#!download|935|429748707|TEST2.pdf|84.309

  • I want to display the both Hindi and English font in single text object

    hi...
    my problem is i want to display both Hindi and English font together in a single text object...
    the data is retrieved from Database in detail section...
    is there any font which supports both Hindi and English font for single text object...
    help me...

    hi Vinayak,
    If I understand your requirement, your field has full length word.
    Now we should split this field into 3 parts.
    Please Create 3 formulas.
    Part1
    stringvar s1;
    s1:= left({field}, InStr({field},"("));
    s1;
    Part2
    stringvar s2;
    s2:= Mid({field},InStr({field},"(")+1 ,InStr({field},")")- InStr({field},"(") -1);
    s2;
    Part3
    stringvar s3;
    s3:= Mid({field}, InStr({field},")"));
    s3;
    Now Place  a Text box in required section. Drag these 3 formula fields into the Text box.
    Right Click the Part2 and apply mangal font.
    Right Click the Part1, Part 3 and apply Arial font.
    I have tried this and implemented successfully. Please let me know if you still face any issue.
    Regards,
    Vamsee

  • Want to display the both hindi and english font in single text object

    hi...
    my problem is i want to display both Hindi and English font together in  a single text object...
    the data is retrieved from Database in detail section...
    is there any font which supports both Hindi and English font for single text object...
    help me...

    hi,
    Is your single Text object contains combination of two strings?
    for example:
    {State}{City}
    If yes,
    Right Click the 1st string object within the Text box and 'Text Formatting' specify the  Hindi Font
    Right Click the 2nd string object within the Text box and 'Text Formatting' specify the  English Font.
    Regards,
    Vamsee

  • Font styles in source xml are not set  on footnote text

    Hi,<br /><br />   could some please help. Not sure what iam missing.<br /><br />Iam using the following code to add footnote for each footnote element in imported xml. Iam running the script after importing xml. footnotes are added successfully but the font styles are not applied to the footnote text. The alerts in the code are as expected.<br /><br />Sample XML:<br /><para>This is begin</para><br /><para>Test footnote one follows<footnote id="f0"><para> FN1 This is<italic>italic</italic> and <bold>bold</bold>.</para><br /></footnote></para><br /><para>This is the second section</para><br /><para>Test footnote two follows<footnote id="f1"><para> FN2 This is<italic>italic</italic> and <bold>bold</bold>.<br /></footnote></para><br /><br />Code:<br /><br />var myGlueCodePath = app.filePath + "/Scripts/xml rules/glue code.jsx"; <br />var myFile = File(myGlueCodePath); <br />app.doScript(myFile); <br /><br />main(); <br />function main(){ <br />     var myDocument = app.activeDocument; <br />     if (app.documents.length != 0){ <br />          var myRuleSet = new Array ( <br />          new processParaBold, <br />          new processParaItalic <br />          ); <br />          with(myDocument){ <br />               var elements = xmlElements; <br />               __processRuleSet(elements.item(0), myRuleSet); <br />          } // End With <br />     } // end if <br />     else{ <br />          alert("No open document"); <br />     } // ende Else <br /><br />     var myXMLElements = new Array; <br />     myXMLElements = myGetXMLElements("//footnote"); <br /><br />     if(myXMLElements.length > 0){ <br />          for(var myCounter = 0; myCounter <= myXMLElements.length-1; myCounter++){ <br />               var myXMLElement = myXMLElements[myCounter]; <br />               var myStartIndex = myXMLElement.texts.item(0).insertionPoints.item(0).index; <br />               var myStory = myXMLElement.texts.item(0).parentStory; <br />               var myFootnoteString = myXMLElement.texts.item(0).contents; <br /><br />               myXMLElement.texts.item(0).contents = ""; <br />               var myInsertionPoint = myStory.insertionPoints.item(myStartIndex); <br /><br />               var myFootnote = myInsertionPoint.footnotes.add(); <br />               myFootnote.insertionPoints.item(-1).contents = myFootnoteString; <br />          } <br />     } <br />} <br /><br />function myGetXMLElements(myXPath){ <br />     var myXMLElements = new Array; <br />     var myRuleProcessor = app.xmlRuleProcessors.add([myXPath]); <br />     try{ <br />          var myMatchData = myRuleProcessor.startProcessingRuleSet(app.documents.item(0).xmlElements.item(0)); <br />          while(myMatchData != undefined){ <br />               var myElement = myMatchData.element; <br />               myXMLElements.push(myElement); <br />               myMatchData = myRuleProcessor.findNextMatch(); <br />          } <br />          myRuleProcessor.endProcessingRuleSet(); <br />          myRuleProcessor.remove(); <br />          return myXMLElements; <br />     } catch (myError){ <br />          myRuleProcessor.endProcessingRuleSet(); <br />          myRuleProcessor.remove(); <br />          throw myError; <br />     } <br />} <br /><br />function processParaBold(){ <br />     var myDocument = app.activeDocument; <br />     this.name = "processParaBold"; <br />     this.xpath = "//footnote/para/bold" <br />     this.apply = function(myElement, myRuleProcessor){ <br />          //myElement.texts[0].applyCharacterStyle(myDocument.characterStyles.item("bol d")); <br />          alert("test bold: " + myElement.texts.item(0).contents); <br />          var myCharacterStyle = myDocument.characterStyles.item("bold"); <br />          if(myCharacterStyle != null){ <br />               alert("bold exists"); <br />               myElement.texts.item(0).applyCharacterStyle(myCharacterStyle); <br />          } <br />          return false; <br />     } <br />} <br /><br />function processParaItalic(){ <br />     var myDocument = app.activeDocument; <br />     this.name = "processParaItalic"; <br />     this.xpath = "//footnote/para/italic" <br />     this.apply = function(myElement, myRuleProcessor){ <br />          //myElement.applyCharacterStyle(myDocument.characterStyles.item("italic")); <br />          alert("test italic: " + myElement.texts.item(0).contents); <br />          var myCharacterStyle = myDocument.characterStyles.item("italic"); <br />          if(myCharacterStyle != null){ <br />               alert("italic exists"); <br />               myElement.texts.item(0).applyCharacterStyle(myCharacterStyle); <br />          } <br />          return false; <br />     } <br />}<br /><br />Thanks

    BTW:
    If you add document xml tag map style, the style process can be ignored.
    Then:
    1. Do myStotry.placeXML(justImportedXMLElement);
    2. iterate the backward in justImportedXMLElement: get the footXMLElement, skip children;
    3.
    var myText = footxmlElement.texts[0];
    var ix = myText.insertionPoints[0].index;
    if(ix == 0){ix = 0;}
    var end = myText.insertionPoints[-1].index;
    myText = myStotry.insertionPoints.itemByRange(ix-1, end+1);
    myText.move(LocatcionOptions.atEnd, myStotry.insertionPoints[ix-1].footnotes.add().insertionPoints[-1])]);
    This will be quicker then the upper.
    jxswm

  • How do I bottom align two different sized text objects?

    I'm using font Arnhem and I'm typing something like this:
    [email protected] (font size 8pt) and then San Francisco, CA 90210 (font size 13pt) in another text object to the right.
    I can't get these two to align at the bottom perfectly.  I has to do with the text sizes but there has to be some way to align these two so that they're both aligned at the same exact point on the bottom.

    Why not just type them in the same text object and apply the formatting at the character level?
    If you must use two objects and they are AreaType:
    Set the type in the left textframe. Style as desired.
    AltShiftDrag a copy of it rightward. Edit the text. Style as desired.
    Set the First Baseline setting (Type>AreaType Options) for both to Leading.
    Set the Leading for both to the same value (not Auto).
    If you must use two objects and they are PointType:
    Set the type in the left textframe. Style as desired.
    AltShiftDrag a copy of it rightward. Edit the text. Style as desired.
    OR
    Add a horizontal ruler guide. Select each PointType objects by its origin point and snap it to the Guide.
    I can't get these two to align at the bottom perfectly.
    The above, of course, assumes you want the two texts to be aligned by their baselines. If you're talking about having the bottom edges of the glyphs themselves aligned, you'll have to do that by converting to paths and using object alignment commands, or by using baseline shift or other manual workarounds because different glyphs in a font are of different dimensions. For example, the capitals in a given font are not necessarily all the same height; the ascenders and descenders are not necessarily all the same lengths. That's why fonts are designed to "float" upon their em squares.
    JET

  • SAPScript Font Style not working in QA

    Hi Folks,
    My client has requested a SAPSCript form change in their 4.7 system.  I have imported the Verdana TT Font family into SAP to meet a business requirement, and created the font family ZVERDANA. All good.  I have created a custom style using the new font family ZVERDANA, and used this custom style in a standard text object, which is working fine in our development environment.  The Standard text even displays in the nominated SAPScript form in development in the Verdana Font.
    I've transported everything to QA, but the Standard text object is not reflecting the font upon printout.  I have verified that the font family exists, and is the same as Dev, and the Style exists and this is also a match for Dev.
    When I view the Standard text object in SO10 with the graphical PC editor, the text appears in Verdana, but when I do a print preview from SO10, or when I generate the nominated Form, it's displaying in courier.  The code in the Standard Text object is as follows:
    /:   STYLE ZINFINIT                                   
    HD   INFINITI SERVICES PTY LTD                                            
    SP   Phone: 03 8911 1234  Fax: 03 8911 1200           
    ST   www.infinitiserv.com.au                          
    SP   Mailing address:                                 
    ST   Locked bag 2226, Melbourne, Victoria 3001  
    /:   STYLE *                                          
    Has anyone encountered an issue like this before, and if so, any thoughts on how to get the TT Font to display outwardly?
    Regards,
    Steve

    Thanks for your quick reply Tamas.  At this point in time, we haven't tried printing the form out yet.  The issue was identified based on on a print preview of the form on the screen.  Similarly, the document is, more often than not, emailed as a PDF.  The print difference is visible in the OTF/PDF/Print Preview views, before we get to a printer.
    However, this is not the case in Dev.
    Cheers,
    Streve

  • How to create a text object at runtime?

    Hi,
    I am using crystal reports for visual studio 2010 and using c# to programming.
    I need to create  a text object in a specific section like section 2. and also I need to control the text object's position and text.
    I tried to move a object like:
    reportDocument1.ReportDefinition.Sections[j].ReportObjects<i>.Left = 0x8760;
    but object's position doesn't change at all.
    How can I do these (create a text object and change a object postion)?
    Thanks

    Hi Don,
    Thank you.
    I have downloaded a RAS ( report application Server ) sample.
    The sample uses the Business Objects Enterprise XI release 2. I am using win 7 and crystal reports for vs2010. Can I use this version of crystal reports to create  a text object at runtime? If not, what is the lowest version I have to purchase to achieve what I want?
    Basicly I need following capabilities at runtime:
    1) craete text objects, line objects, image objects.
    2) change text object, line object and image object positions, sizes, values of text object. If can I like to be able to change font as well.
    3) supress objects, sections. 
    4) change section's height

Maybe you are looking for

  • Is it possible to connect two iPads in order to have a two page screen?

    I use Goodreader to read music scores in rehearsal and performance. The display is one page vertically and requires a great deal of "page turning." the magic bullet would be a way to have two iPads side-by-side interfaced in such a way so as to have

  • FTPSVC/SMTP Starting then Stoping immediately

    Hi, When i am starting  FTPSVC or SMTP , its starting, then stoping immediately with this messages : - "Services on local computer started and then stoped. Some services stop automatically if they are not in use by other services or programs " Basica

  • Using of ipod in india

    i hav brought an ipod in america.can i use that in india by just chainging the adaptor??

  • Business content extractors

    Hi All, Why is it suggested to use business content extractors when compared to custom generated extractors? performance ?? if yes, how does it affect... can anyone please explain?? Thanks in advance. --Monica

  • Linux server - ODI agent

    Hi guys, I can start the ODI agent fine but I keep logging in to find the agent has stopped/crashed when using the ODI console. This isn't going to be very good when the monthly schedules run....Is the easiest method to avoid this to schedule a shell