Custom Views: Set style of text in custom HTML tags

hi all, I'm using an extended JEditorPane to render HTML containing custom tags e.g. <mytag>Text</mytag>
My ViewFactory dynamically loads a class based on the name of the tag to return the View for that tag. (The idea being you can add any tag, by just providing a View class to render it). It's working to the extent that I can use the View.paint() method to paint a square of text before and after the content element.
What I need to do is set the style (attributes) of the text contained in the custom tags. Is this possible?
A call to doc.setCharacterAttributes(startoffset, endoffset, attrs, true); from the View results in a "Attempt to mutate in notification", possibly because the HTMLDocument is locked at this time.
Any help/advice would be greatly appreciated.
Thanks.

I'll rephrase. Is it possible to change the HTMLDocument from a View object. Forgive my lack of understanding.

Similar Messages

  • Makina text area read html tags

    How can i make a html text area recognize html tags.

    According to http://www.oracle.com/webapps/online-help/reports/10.1.2/state/content/navId.3/navSetId._/vtTopicFile.htmlhelp_rwbuild_hs%7Crwwhthow%7Cwhatare%7Coutput%7Ca_inlinehtml%7Ehtm/
    Oracle Reports only supports a specific set of HTML tags. Have you already checked if they match? Maybe you have to use REPLACE to translate them into "proper" ones in your report SQL statement.
    Have you already had a direct look in your data, if the HTML tags are encoded in some way. eg. & lt; for < ?
    Patrick
    My APEX Blog: http://inside-apex.blogspot.com
    The ApexLib Framework: http://apexlib.sourceforge.net
    The APEX Builder Plugin: http://sourceforge.net/projects/apexplugin/

  • Text Catalog showing HTML tags

    We are having an issue after applying Bundle #22 for HCM 8.9 where the calls to the Text Catalog are now showing HTML tags. Has anyone else seen this? Im trying to figure out if its the bundle or something maybe with our customizations that have affected this change. Basically the page where the text from the text catalog displays now shows not only the text, but raw HTML tags as well on the page. Example: BR, B
    Thanks!
    Edited by: CoryU on May 11, 2010 2:00 PM

    We are having an issue after applying Bundle #22 for HCM 8.9 where the calls to the Text Catalog are now showing HTML tags. Has anyone else seen this? Im trying to figure out if its the bundle or something maybe with our customizations that have affected this change. Basically the page where the text from the text catalog displays now shows not only the text, but raw HTML tags as well on the page. Example: BR, B
    Thanks!
    Edited by: CoryU on May 11, 2010 2:00 PM

  • Text Search skiping HTML tags

    I have a table containing clob column.
    select code, details from search order by code;
    CODE DETAILS
    4 just a <b>test </b>insert
    5 just a <b>test</b> insert
    9 <HTML>just a <i>test</i> insert</HTML>
    10 checking test insert
    I have created a context index and add html tags in the stop list.
    exec ctx_ddl.create_stoplist('mystop', 'BASIC_STOPLIST');
    exec ctx_ddl.add_stopword('mystop', '<b>');
    exec ctx_ddl.add_stopword('mystop', '</b>');
    CREATE INDEX searchi ON search(details)
    INDEXTYPE IS CTXSYS.CONTEXT PARAMETERS
    ('FILTER CTXSYS.AUTO_FILTER SECTION GROUP CTXSYS.AUTO_SECTION_GROUP STOPLIST MYSTOP');
    But when I search 'test insert' it only shows the following rows
    SQL> SELECT score(1), code, details FROM search WHERE CONTAINS(details, 'test insert', 1) > 0 ORDER BY score(1);
    SCORE(1) CODE DETAILS
    5 10 checking test insert
    5 9 <HTML>just a <i>test</i> insert</HTML>
    I would like to define a text index which skips the html keywords and returns all the rows contain the searching phrase

    Since you did not use code tags in your post, most of your html does not show, so it is difficult to tell what html is in your data or what values you set for your stopwords. One problem with stopwords is that, although the word is not indexed, it still expects some word where the stopword was, so searching for "word1 word2" will not find "word1 removed_stopword word2". How about using a procedure_filter as demonstrated below? I only removed a few tags, so you would need to either expand it to include others or searching for starting and ending tags and remove what is inbetween.
    SCOTT@orcl_11g> CREATE TABLE search
      2    (code      NUMBER,
      3       details  CLOB)
      4  /
    Table created.
    SCOTT@orcl_11g> INSERT ALL
      2  INTO search VALUES (4, 'just a <b>test</b> insert')
      3  INTO search VALUES (5, 'just a <i>test</i> insert')
      4  INTO search VALUES (9, '<HTML>just a test insert</HTML>')
      5  INTO search VALUES (10, 'checking test insert')
      6  SELECT * FROM DUAL
      7  /
    4 rows created.
    SCOTT@orcl_11g> CREATE OR REPLACE PROCEDURE myproc
      2    (p_rowid    IN ROWID,
      3       p_in_clob  IN CLOB,
      4       p_out_clob IN OUT NOCOPY CLOB)
      5  AS
      6  BEGIN
      7    p_out_clob := REPLACE (p_in_clob, '<html>', '');
      8    p_out_clob := REPLACE (p_out_clob, '</html>', '');
      9    p_out_clob := REPLACE (p_out_clob, '<HTML>', '');
    10    p_out_clob := REPLACE (p_out_clob, '</HTML>', '');
    11    p_out_clob := REPLACE (p_out_clob, '<b>', '');
    12    p_out_clob := REPLACE (p_out_clob, '</b>', '');
    13    p_out_clob := REPLACE (p_out_clob, '<B>', '');
    14    p_out_clob := REPLACE (p_out_clob, '</B>', '');
    15    p_out_clob := REPLACE (p_out_clob, '<i>', '');
    16    p_out_clob := REPLACE (p_out_clob, '</i>', '');
    17    p_out_clob := REPLACE (p_out_clob, '<I>', '');
    18    p_out_clob := REPLACE (p_out_clob, '</I>', '');
    19  END myproc;
    20  /
    Procedure created.
    SCOTT@orcl_11g> SHOW ERRORS
    No errors.
    SCOTT@orcl_11g> BEGIN
      2    CTX_DDL.CREATE_PREFERENCE ('myfilter', 'PROCEDURE_FILTER');
      3    CTX_DDL.SET_ATTRIBUTE ('myfilter', 'PROCEDURE', 'myproc');
      4    CTX_DDL.SET_ATTRIBUTE ('myfilter', 'ROWID_PARAMETER', 'TRUE');
      5    CTX_DDL.SET_ATTRIBUTE ('myfilter', 'INPUT_TYPE', 'CLOB');
      6    CTX_DDL.SET_ATTRIBUTE ('myfilter', 'OUTPUT_TYPE', 'CLOB');
      7  END;
      8  /
    PL/SQL procedure successfully completed.
    SCOTT@orcl_11g> CREATE INDEX searchi
      2  ON search (details)
      3  INDEXTYPE IS CTXSYS.CONTEXT
      4  PARAMETERS ('FILTER myfilter')
      5  /
    Index created.
    SCOTT@orcl_11g> SELECT token_text FROM dr$searchi$i
      2  /
    TOKEN_TEXT
    CHECKING
    INSERT
    TEST
    3 rows selected.
    SCOTT@orcl_11g> COLUMN details FORMAT A35
    SCOTT@orcl_11g> SELECT score (1), code, details
      2  FROM   search
      3  WHERE  CONTAINS (details, 'test insert', 1) > 0
      4  ORDER  BY score (1)
      5  /
      SCORE(1)       CODE DETAILS
             3          4 just a <b>test</b> insert
             3          5 just a <i>test</i> insert
             3          9 <HTML>just a test insert</HTML>
             3         10 checking test insert
    4 rows selected.
    SCOTT@orcl_11g>

  • Vertical text. Can FireFox display a vertical text? Which HTML tags should be used for that?

    The site http://habrahabr.ru/blogs/css/58732/ recommends a way for using vertical text in HTML/CSS (see example below). However my instance of Firefox 3.6.22 does not display this vertical text. Please let me know your recommendations/
    <html>
    <head>
    <title>1</title>
    <style>
    <!--
    .vertical { overflow:hidden; line-height:30px; position:relative; white-space:nowrap; width:30px; height:200px; border:1px solid #999; }
    -->
    </style>
    <body>
    <div class="vertical">Testing text</div>
    </body>
    </html>

    See: https://developer.mozilla.org/En/CSS/-moz-transform

  • Extract text file with HTML tags from JTextPane

    hello world
    I have a big problem !
    I am creating an applet with a JTextPane ...
    so I can write text, (bold, italic etc), i can insert images.
    Now i want to create a text file with all the HTML tags
    corresponding to what I wrote in my JTextPane.
    I want to have and save the HTML file corresponding to what i wrote ...
    Is it possible ? Help me please ....
    Jeremie

    writing to a file from an applet is going to take a fair amount of work on your part.
    in order to write to a file from your applet, you have to use servlets or jsp to write to a file on your server. if you wish to write locally, look into signing your applet or policy settings of your browser.
    for writing to a file to the server, i suggest you look into servlets and tomcat to run the servlets.
    i just finished a project that used servlets and they take some time to figure out, but its definitely worth your time.
    here are some websites...
    http://www.j-nine.com/pubs/applet2servlet/Applet2Servlet.html
    http://jakarta.apache.org
    other websites have tutorials that you can look at too
    Andy

  • Custom Viewer does not show all folio / Custom Viewer zeigt nicht alle folios

    Hallo, ich bin neu hier im forum und habe gerade meinen ersten viewer zu apple gesendet.
    Mein problem ist, das in dem viewer nur eine kostenlose ausgabe unseres magazins , und das auto-renewable angezeigt werden. Wir haben allerdings noch drei weitere Ausgaben die non-consumable sind. Und diese werden nicht angezeigt. Die product-id´s sind bei apple und im Adobe Folio Builder gleich.
    Würde mich freuen wenn mir da jemand helfen könnte.
    mfg Uhtred
    Hello, I'm new to this forum and have just sent my first viewer to apple.
    My problem is that output in the viewer just one of our magazine free, and the auto-renewable appear. We have, three more issues, the non-consumable. And these are not displayed. The product-id's are the same for Apple and Adobe in theFolio Builder.
    Would be glad if someone could help me there.
    Uhtred

    Sign in to the Folio Builder panel the new Adobe ID (the one you specify as Title ID in DPS App Builder), and create a new folio. To get the articles from the old folio into the new one, you have two choices.
    (1) Use the Import command to import the articles. This works well if you set up your structure properly, including creating a sidecar.xml file.
    (2) Share the folio from the old Adobe ID to the new one. Use the Copy To command to copy over the articles.
    Then specify the folio metadata and cover images, and publish the folios.

  • How do I change the style of text in an HTML Snippet?

    Hello everyone,
    I'm using an HTML snippet with an iFrame tag in it. What formatting code do I include in the snippet so that the style of the text is the same as that of the default text object for the particular iWeb theme I'm using?
    Much obliged,
    Gregory

    Use CSS to format fonts. Look here for info.

  • Regex: Extracting text between two HTML tags

    Hello,
    the common answer to this question would be
    <tag>(.*)</tag>
    or
    <tag>[^<]*But I have LFs (and whitespace) around the tags:
    <html>
      <body>
        One text line to be retrieved.
      </body>
    </html>So I tried
    (?s)<body>(.*)</body>But that didn't help.
    What's missing?

    Thanks for your replies.
    @Sabre
    I tried your suggestion with the following code to no avail
    import java.util.*;
    import java.util.regex.*;
    public class X {
      public static void main(String[] args) {
          String s=
    "<html>\n"+
    "  <head>\n"+
    "\n"+
    "  </head>\n"+
    "  <body>\n"+
    "    One <u>text line</u> to be retrieved.\n"+
    "  </body>\n"+
    "</html>";
        String regex= "<body>([^<]*)</body>";
        Pattern p = Pattern.compile(regex); // Create the pattern.
        Matcher matcher = p.matcher(s); // Create the matcher with the string.
        while (matcher.find()) {
          System.out.printf("Found: \"%s\" from %d to %d.%n",
                   matcher.group(), matcher.start(), matcher.end()-1);
    }@ejp
    Paul had a similar objection. But as I've written, my html string will always have this same structure and all I have to do is to extract the text. So if regex doesn't work in that case, I'd rather prefer two indexOf-s instead of bothering a parser.

  • Want text input containing HTML tags to appear as HTML in output format

    Hi,
    We have a table in Oracle database that has a column named detail,one of its values is like this: <bold><italics>Good Morning</italics></bold>. What our client wants is that the output format should show: <b><i>Good Morning</b></i>. That is,Bi Publisher should be able to parse the HTML tags and provide the desired output. Please tell me how to achieve this. Any help is much appreciated.
    Thanks and regards,
    Debarati,
    [email protected]

    Hi,
    have a look here (http://blogs.oracle.com/xmlpublisher/2007/01/formatting_html_with_templates.html) to get an idea.
    regards
    Rainer

  • Custom Importing Setting

    **Custom Importing Setting**
    I have discovered the Custom Importing settings in the iTunes Advanced Preferences. I have some questions/comments and would like some feedback if possible
    Stereo Bit Rate - I think I will set this at 192 kbps for the better quality
    Sample Rate - I think I will set this to 44.1k, which is the CD standard, but I am wondering what rate is used for the "Auto" setting? It doesn't display when you select this setting?
    Channels - Again, I think I will set this at "Stereo" for better quality but I am also wondering what "Auto" is?...stereo or mono?
    Stereo Mode - I don't think I want to select "Joint Stereo" because from the research I've read on that, it is lossy and sort of approximates the stereo field but is not true stereo. So I assume the "Normal" setting is just regular stereo?
    Filter Frequencies Under 10Hz - the purest in me does NOT want to select this option but can the human ear even detect that low of a frequency?...then again, we can probably feel it more than we hear it, which is still important in a lot of rock, rap and pop music.
    any thoughts, comments, advice?...

    That seems to be exactly the same as the "Highest" setting (192kbps). If quality is most important, you should choose AAC instead of mp3. A 192kbps AAC VBR file will sound a lot better than 192kbps mp3.

  • How to customize the content set in text as part of tag cq:text property="text"/

    We use the tag <cq:text property="text"/> to get the content, which is set in the jcr property "text".  Text was set in Richtext component and it has hyper link.
    Now, we have to customize the text.
    Example:-
    Actual Text in 'text' property:-
    <p>Click <a data-action="Hyperlink" data-upc-tooltip-type="none" href="/content/www-abc-healthcare-ch/en/offer.html">here</a> for the link</p> <p></p>
    After customization in 'text' property:-
    <p>Click <a data-action="Hyperlink" data-upc-tooltip-type="none" href="/content/www-abc-healthcare-ch/en/offer">here</a> for the link</p> <p></p>
    i.e .html has been removed.
    I tried customizing and set back to text attribute using <c:set var="text" value="<CustomizedText>" /> but even after that tag <cq:text property="text"/> retrieves the old content i.e with .html
    Please suggest how to override text content, so that the tag <cq:text property="text"/> will print customized text.

      Which version of cq? Is Strict Extension Check enabled at  http://<host>:<port>/system/console/configMgr/com.day.cq.rewriter.linkchecker.impl.LinkCheckerTra nsformerFactory
    Thanks,
    Sham

  • HTML tags displayed with the text in "Notification" area

    We want to display an HTML formatted message in the "notification" area, but the HTML tags are being escaped and thus are displayed along with the text. We are using Application Express 2.2.1.00.04. The application has been handed off to us to support and we have no experience with APEX. So I hope I am explaining this correctly.
    The process to display the message is as follows:
    After submission, a page validation fires, which is of type "function returns boolean": "return some_function('P100_MESSAGE',2nd_arg);".
    In "Error Message" is "&P100_MESSAGE."
    The function returns true when the validation is successful. When validation fails, it returns false, setting 'P100_MESSAGE' to some error message - for example: "&lt;li&gt;Phone number is not numeric&lt;/li&gt;&lt;li&gt;Email address is not valid&lt;/li&gt;".
    Our template has this in the body definition:
    #NOTIFICATION_MESSAGE##SUCCESS_MESSAGE##BOX_BODY#
    As I understand it, #NOTIFICATION_MESSAGE# will be replaced with the value of 'P100_MESSAGE'.
    I've displayed 'P100_MESSAGE' on my page to confirm its contents and it is rendered correctly with bullets. But the notification area does not show bullets. It displays the text and the HTML tags.
    Is there anything obvious we can do to fix this problem? Thanks

    I 've changed P100_MESSAGE to text field, text field (disabled, saves state), text field (disabled, does not save state), and textarea, display as text, etc. It is originally set to Hidden type (because it is only to be displayed in the notification area). But changing it to various types makes no difference as to how it is displayed in the notification area. Of course, when it's not hidden, then it's also displayed on the page, among to other page elements,which is not acceptable.
    Thanks-
    -j

  • HTML tags in text-only e-mail notification (with HTML attachment)

    Greetings,
    Our "Purchase Order Review" e-mail notifications (as generated by the WF-Mailer) have HTML tags in the message body (which is "plain-text" text-only), with an HTML attachment. (The attachment looks good, and is what we are expecting.) All our e-mail notifications are text-only (which is how we want them), and this is the only kind of notification that is generating HTML tags in the 'text-only' message body.
    We'd like to keep the HTML attachment as it is, but we want to have the e-mail message body be text (without any HTML tags). The other option that would be acceptable is to NOT have any message content at all, and only the HTML attachment.
    Can either of these options be done, and how do we go about doing them?? Thanks!! -- Tom
    Tom Buck
    [email protected]
    PS: Here is a partial sample of the "text-only" message content...
    <HTML><HEAD></HEAD>
    <BODY BGCOLOR="#FFFFFF"><b>Oracle Workflow Notification (FYI)</b>
    <br>
    <hr>
    <P><table width=100% border=0 cellpadding=2 cellspacing=1 cols=3 rows=2>
    <!-- header -->
    <tr>
    <!-- ORACLE, ship-to, PURCHASE-ORDER -->
    <td width=45% valign=top>
    <!-- ORACLE -->
    <font color=black size=+2>
    BUTLER MANUFACTURING
    </font><br>
    <font color=black> BUTLER MANUFACTURING COMPANY
    <br> BUTLER MANUFACTURING HEADQUARTERS
    <br> 1540 GENESSEE ST.
    <br> KANSAS CITY
    , MO
    64102
    <br> US
    </font> </br>
    </td>
    <td width=25% valign=top>
    <!-- ship-to -->
    etc..., for another couple hundred lines. -- Tom

    in the notifications properties you will see two tabs, in one you can enter your message in text and in another you can enter in html. not sure if you had tried these.
    hth
    satish paul
    Greetings,
    Our "Purchase Order Review" e-mail notifications (as generated by the WF-Mailer) have HTML tags in the message body (which is "plain-text" text-only), with an HTML attachment. (The attachment looks good, and is what we are expecting.) All our e-mail notifications are text-only (which is how we want them), and this is the only kind of notification that is generating HTML tags in the 'text-only' message body.
    We'd like to keep the HTML attachment as it is, but we want to have the e-mail message body be text (without any HTML tags). The other option that would be acceptable is to NOT have any message content at all, and only the HTML attachment.
    Can either of these options be done, and how do we go about doing them?? Thanks!! -- Tom
    Tom Buck
    [email protected]
    PS: Here is a partial sample of the "text-only" message content...
    <HTML><HEAD></HEAD>
    <BODY BGCOLOR="#FFFFFF"><b>Oracle Workflow Notification (FYI)</b>
    <br>
    <hr>
    <P><table width=100% border=0 cellpadding=2 cellspacing=1 cols=3 rows=2>
    <!-- header -->
    <tr>
    <!-- ORACLE, ship-to, PURCHASE-ORDER -->
    <td width=45% valign=top>
    <!-- ORACLE -->
    <font color=black size=+2>
    BUTLER MANUFACTURING
    </font><br>
    <font color=black> BUTLER MANUFACTURING COMPANY
    <br> BUTLER MANUFACTURING HEADQUARTERS
    <br> 1540 GENESSEE ST.
    <br> KANSAS CITY
    , MO
    64102
    <br> US
    </font> </br>
    </td>
    <td width=25% valign=top>
    <!-- ship-to -->
    etc..., for another couple hundred lines. -- Tom

  • Remove HTML tags from a text area

    Hi, here is my problem:
    I have a form with a text area item; this item is “Display as Editor HTML standard”. So it is possible to enter formatted text with tags HTML. Then I save the text in a table. In the column the text maintain the HTML tags. Afterwards I can put the text in a report, and I can see the formatted text with the tags HTML interpreted.
    But I need also to use that text for other aims, (i.e. sending it in a mail) with the html tags removed.
    Is there any way to remove HTML tags from a text item?
    Regards
    Dario

    From http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:769425837805
       FUNCTION str_html (line IN VARCHAR2)
          RETURN VARCHAR2
       IS
          x         VARCHAR2 (32767) := NULL;
          in_html   BOOLEAN          := FALSE;
          s         VARCHAR2 (1);
       BEGIN
          IF line IS NULL
          THEN
             RETURN line;
          END IF;
          FOR i IN 1 .. LENGTH (line)
          LOOP
             s := SUBSTR (line, i, 1);
             IF in_html
             THEN
                IF s = '>'
                THEN
                   in_html := FALSE;
                END IF;
             ELSE
                IF s = '<'
                THEN
                   in_html := TRUE;
                END IF;
             END IF;
             IF NOT in_html AND s != '>'
             THEN
                x := x || s;
             END IF;
          END LOOP;
          RETURN x;
       END str_html;There's also a reqular expression approach that I've not tried. Remove HTML Tags and parse the text out of it

Maybe you are looking for

  • Looking for Upgrade Disk: 32bit, Vista to Windows 7 Home Premium

    Hi, Computer novice here.   Accidently ordered x64bit and need the x32.  Best case scenario: Anyone in the Cumming GA area who could let me borrow their upgrade disc?  Spoke to Lenovo help and they said can't send me the correct disk becuse the upgra

  • BPM Split and Merge

    Hi...    I want to do scenario like file split and merge using BPM. for that i have used, 1.Receive 2.Transformation(1:N) 3.Block(ForEach) 4.Control 5.EndBlock 6.Transformation(N:1) 7.Send. while executing the scenario, the message is going to the qu

  • Increase distance between objects w/o resizing the objects

    Is it posible to increase distance between objects in illustrator cs3 without resizing the individual objects? For example, I have a series of circles separated from one another by about 20 pixels, aligned into a grid-like formation.  I would like to

  • Tax calculation matter - GL a/c with service tax chargeable

    Dear Experts, I really do not understand why this happen. Any expert can help me? Thank you. GL posting for C/N issued:- Car Park reversal         129.03 Service Tax 5%               6.45 Total =                        135.48 <PROBLEM> Document C/N p

  • Tecra A9 - Recovery Disc Creator malfunctioning

    I've been trying to make recovery discs for my Tecra A9. I've successfully made the two System Recovery Discs (DVD-R), but when I try to make the Applications Disc I get a errormessage right after the program wants me to verify that i've put a blank