Scripting Window - Text Area?

Hi everyone,
I'm currently implementing Jython in a program I'm writing, and want to implement a Text Area or something similar much like a command prompt - where you can write commands on the bottom line, and your results gets written above it.
I was wondering - has anyone come across a premade class like this? I know I can build one using two separate text components, but I was wondering if there's a better (premade?) way.
Thanks,
Wojciech

I was actually working on this myself a while back.
You have 2 options:
1 - Master a TextComponent. You can then override it so that the up arrows wont work or whatever so you can only edit the last line. Basically you have to do a lot of work to force it to act like a terminal.
2 - Outside the box... render your own. I did this by creating my own library that has a class for storing text, a class for intercepting keystrokes so i could do custom things, a class for rendering the terminal on screen. That was essentially a JPanel and after a long time of looking into rendering fonts i saved myself a lot of grief and just used ".drawString()".
It only took a day or two for all of this. The hardest part is just the rendering and arrangement of the text on the screen in the JPanel.
I didnt do this to emulate a Terminal however. So in your case... ignoring the visual for a sec, with Java how much of the Terminal functionality can you actually copy?

Similar Messages

  • In secondary window texts are not appeaerd in smartform

    hi to all
      bfore main window,i create one window for header data.
    in this window only texts are there.
       in main window item data is dere.
    item data was appeared in main window.
    but in header data window header texts were not appeaerd,so
    plz giv me idea.
      in that window, used one header template.
        created text editor for each text.
    is there any problem with header template.if nt,after created header template,wat ll i do,it ll b assign to  anywhere.
    giv me reply asap.
    reagrds,
    satya
    points ll b rewarded.

    Hi,
    Sorry if I've not understood your question, but all this 'wht', 'nt', 'plz' stuff is a bit difficult to follow.
    Anyway, you've got a window, in this you've defined a template, then some text elements with variables?  Have you assigned the text elements to cells of the templates by putting values in the output tab?  If not the text will not appear.
    Regards,
    Nick

  • CS4 v10.0 Action Script window Text overlapped

    I just installed CS4 Production bundle, and have been
    entering in an Action Script to load a movie. When I type the word
    'loadMovie', the automatic feature performs the word completion,
    but the cursor is not adjusted to the end of the text, and the
    result looks 'jumbled' and virtually impossible to edit.
    The same result if I use the 'Script Assist' where the line
    generated looks 'garbled'.
    I have no clue what the problem may be.

    Ned,
    I'd love to check it out but I don't under stand I have copied and pasted what you viewed on you site.
    ÐÏࡱáÿÿÿÿÿÿÿÿÿÿÿÿýÿÿÿþÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿ ÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿR
    A$
    Sorry, I still cant get it to work.

  • Dump error when clicked on text elements in SAP Script window

    Hi All,
    There is an inclusion in SAP Script. I have written the code in driver program. I need to pass the value to SAP Script in the requested position. But when I go to SE71 > Form Name > Change or Display > MAIN Window > Text Elements > I get a dump error.
    Category               ABAP Programming Error
    Runtime Errors         DATA_LENGTH_TOO_LARGE
    Except.                CX_SY_RANGE_OUT_OF_BOUNDS
    ABAP Program           SAPLSTXK
    Application Component  BC-SRV-SCR
    Date and Time          30.04.2014 20:00:08
    Short text
         Invalid partial field access: Length is too large
    What happened?
         Error in the ABAP Application Program
         The current ABAP program "SAPLSTXK" had to be terminated because it has
         come across a statement that unfortunately cannot be executed.
    What can you do?
         Note down which actions and inputs caused the error.
         To process the problem further, contact you SAP system
         administrator.
         Using Transaction ST22 for ABAP Dump Analysis, you can look
         at and manage termination messages, and you can also
         keep them for a long time.
    Error analysis
         An exception occurred that is explained in detail below.
         The exception, which is assigned to class 'CX_SY_RANGE_OUT_OF_BOUNDS', was not
          caught in
         procedure "TOKEN_COMMENT" "(FORM)", nor was it propagated by a RAISING clause.
         Since the caller of the procedure could not have anticipated that the
         exception would occur, the current program is terminated.
        The reason for the exception is:
        In the executed program "SAPLSTXK", the system attempted to access the field
        "ITF_TOKEN" of the type "C" and with the length 255 using the length 272.
        However, a partial field access with a length specification that is
        larger than the field length is not allowed.
    How to correct the error
        Reduce the length used to access the field.
        If the error occures in a non-modified SAP program, you may be able to
        find an interim solution in an SAP Note.
        If you have access to SAP Notes, carry out a search with the following
        keywords:
        "DATA_LENGTH_TOO_LARGE" "CX_SY_RANGE_OUT_OF_BOUNDS"
        "SAPLSTXK" or "LSTXKFRN"
        "TOKEN_COMMENT"
        If you cannot solve the problem yourself and want to send an error
        notification to SAP, include the following information:
        1. The description of the current problem (short dump)
           To save the description, choose "System->List->Save->Local File
        (Unconverted)".
        2. Corresponding system log
           Display the system log by calling transaction SM21.
           Restrict the time interval to 10 minutes before and five minutes
        after the short dump. Then choose "System->List->Save->Local File
    2937 * todo empty comment ???
    2938       if g_tm_open    eq true or     " Section
    2939          g_tm_b_close eq true.
    2940         l_token = '\chcbpat0'.
    2941         l_len = strlen( l_token ).
    2942         token_control = true.
    2943         assign l_token to <itf1>.
    2944         perform put_itf1_new using l_len.
    2945         perform token_line_begin changing l_next_token.
    2946       else.                          " without section
    2947         concatenate '\chcbpat0\line' g_cf_string l_cbpat_token into l_token.
    2948         l_len = strlen( l_token ).
    2949         token_control = true.
    2950         assign l_token to <itf1>.
    2951         perform put_itf1_new using l_len.
    2952       endif.
    2953     elseif l_next_token-code eq ')L'.         " \par
    2954       l_token = '\par'.
    2955       l_len = strlen( l_token ).
    2956       token_control = true.
    2957       assign l_token to <itf1>.
    2958       perform put_itf1_new using l_len.
    2959     elseif l_next_token-code eq '(C' or       " \par + format
    2960            l_next_token-code eq ')C' or
    2961            l_next_token-code eq '(&' or
    2962            l_next_token-code eq 'TA' or
    2963            l_next_token-code eq 'SC' or
    2964            l_next_token-code eq 'ST'.
    2965       concatenate '\chcbpat0\par' g_pf_string g_cf_string l_cbpat_token into l_token.
    2966       l_len = strlen( l_token ).
    >>>>>       itf_token(l_len) = l_token.
    2968       token_control = true.
    2969       assign l_token to <itf1>.
    2970       perform put_itf1_new using l_len.
    2971     endif.
    2972
    2973 * Step 7: (L to disarm
    2974   if g_compose eq true and
    2975      l_next_token-code eq '(L'.
    2976     perform read_next_itf_token(rstxscan) using p_token.
    2977   endif.
    2978
    2979 ENDFORM.                    " token_comment
    2980 *&---------------------------------------------------------------------*
    2981 *&      Form  create_lang_info
    2982 *&---------------------------------------------------------------------*
    2983 *       add default language to rtf
    2984 *----------------------------------------------------------------------*
    2985 *      -->P_HEADER  text
    2986 *      <--P_RESULT  text
    How do I open the text elements? I need to pass the variable inside SAP Script.
    Please Help. The requirement is pending from very long. Not able to rectify this issue.
    Regards,
    Rekha

    Hi,
    There is a SAP Note about this problem
    566794 - Runtime error: STRING_OFFSET_TOO_LARGE during conversion
    Correction Instructions
    Correction Instructions
    Software Component
    Valid from
    Valid to
    Number
    SAP_BASIS
    46B
    46D
    473267
    SAP_BASIS
    610
    620
    473185
    Support Packages & Patches
    Support Packages
    Software Component
    Release
    Support Package
    SAP_BASIS
    46B
    SAPKB46B48
    46C
    SAPKB46C39
    46D
    SAPKB46D28
    610
    SAPKB61027
    620
    SAPKB62014
    Regards
    Miguel

  • Need to compare html text area values by using java script

    I have one html text area in my JSP file. when i click on that text area, a pop-up will come, in that pop-up i have list of items. So after selecting a item from that pop-up list, need to click okay. so that text area will update with the selected value.
    In this case, i need to compare the first text area value and updated text area value. How can i do that in Java Script.

    I suggest you look for a Javascript forum to ask questions about Javascript. This is a Java forum.

  • Can a script manually insert a delete (or backspace) into a text area?

    I'm new to action script, so this may have a simple answer, sorry if that's the case.
    I have a little movie created with a simple purpose of trying to mimic a system like cell phones have for character input.
    There are two text areas, one hidden off the screen that accepts the input from the user; a second text area in on screen and displays what the user had entered after some basic processing on the input.
    The hidden text area is pretty basic with listener that is responsible for grabbing the input keys and then mangling them to be inserted into the displayed text area based on the cell phone text entry multi-tap rules. Example user press 2-2-2  and the hidden input accepts 222 and then appends 'C' to the display text area. That's working great, but I have a problem if the user wants to delete from the display text area. I can't find a way to insert a delete or backspace key into the display text area. I've tried using StringFromCharCode (8) // Key.BACKSPACE, but that doesn't work. That just displays one of those undefined glyphs. I figure that things like clear, and delete are handled somewhere higher in the input chain and that's where I'm having a problem.
    I've looked, but I can't find a way to delete a single character from the text area. I was thinking if I could find the cursor location that I could just use some delete character method to get the job done, but I couldn't find how to do that.
    Any ideas on how to pull off manual delete function in a text area?

    Ned, I do really want to manually (by method of code) trigger a delete in a text area. The delete (or backspace) that I want added to the text area isn't directly entered by the user, it's the result of several key presses by the user. That's why I called it "manual" because it's done by the code, not by the user's direct input.
    Think about how text entry works on most phones... if you want to enter a letter you have to cycle through all the letters on a single key until you get to the character desired. As I stated before, if you want a 'c' you need to press 2 button 3 times. This is basically what I'm trying to do, but I want to add the ability to delete a character too if the correct sequence in entered, for example a sequence of ### would equal a backspace.
    Rothrock, I think you were thinking the same thing that a single key is used to do a backspace.
    I was thinking that I could possibly insert key event into the event queue for the text area to process, but I wasn't sure about that.
    Sorry, if this is confusing, I know it's not a straight forward design. I need onscreen and offscreen text areas with the onscreen one acting as a slave of the offscreen one.
    The way the code currently works is hidden text area had a listner that responds to changes, and that handler processes the key entered and deletes that character from the hidden text area. After the full sequence of characters (say 2 button has been pressed 3 times) the handler then sends the resulting character into the display text area. This part of the code works great. I can add any character including some specials like tab and newline. However if I want the text area to delete a character I don't have a way to do that. That's why I tried to insert the backspace key (0x08 or ^H, for other oldschoolers), but using that as a char code or string from char code doesn't work.
    I had also tried to create to set the focus to the display text area then create and dispatch a backspace keydown and keyup events to the visible text area and then return the focus back to the hidden textarea, but... no luck.

  • I have just intalled PSElements 12 on a new PC with windows 8.1. It installed ok but when I open it up it displays different than on my windows 7 PC. The buttons and text are tiny and almosy impossible to see even when I drag it to full screen. How do I a

    I have just intalled PSElements 12 on a new PC with windows 8.1. It installed ok but when I open it up it displays different than on my windows 7 PC. The buttons and text are tiny and almosy impossible to see even when I drag it to full screen. How do I adjust it to look normal?

    Hi Paul ,
    It could be a compatibility issue as well as Acrobat 8 is an older version.
    Do you get any error message while registering for the product?
    Try repairing it and once and also check for updates as well.
    Is it happening with all the word files or any specific one'?
    Regards
    Sukrit Dhingra
    Acrobat 8 and Windows 7 Don't Work

  • Trying to open a page in IE-tab using javascript, script type="text/javascript" window.location.href="chrome://coralietab/content/container.html?url=0,myurl" /script Error:Component returned failure code:0x80004005 (NS_ERROR_FAILURE) [nsIDOMLocation.href]

    I am trying to open a page in IE-tab using javascript like this, <script type="text/javascript"> window.location.href = "chrome://coralietab/content/container.html?url=0,myurl" ;</script>.Error occured : [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIDOMLocation.href]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame ::myurl :: load :: line 234" data: no] I have IE-Tab plug-in installed..when I open the same link manually in mozilla,it works fine and page gets opened in Ie-tab.

    The only way this might be possible is by using the HostContainer object
    to access the HTML page and do it from there.

  • Make text areas and textfields streach as window resizes

    im using the border layout for most of my panels. how do i make text areas and textfields stretch as the window resizes?

    Components placed in BorderLayout.CENTER will resize as the window resizes.
    You will likely need to have nested JPanels, with different layouts, to create the ultimate layout of all your components in a frame, especially for non-trivial applications.
    If you need specific help with layouts, you'll have to post an SSCCE.

  • Scrollable Text Area

    Hi, I have inherited a website that uses javascript/DHTML to
    create a scrollable text area. I suspect it was created using a
    Dreamweaver extension as the pages with scrollable text contain the
    following comment lines:
    // Extension developed by David G. Miles
    // Original Scrollable Area code developed by Thomas Brattli.
    I’m no Javascript or DHTML expert but it looks good and
    it still works in IE7. My question is, how do I edit the text that
    scrolls? It is not initially visible in design view, unless I place
    the cursor in either of these two lines in the code window:
    <div id="divContainer" style="z-index: 2">
    <div id="divContent">
    Although this reveals the text in the design window, if I try
    and click on the text to edit it, it disappears. I can find the
    text in the code window, and I could edit it there, but I have a
    lot of changes to make and I would prefer to make them with some
    visual feedback of the formatting. Does anybody know if this is
    possible?
    I've tried searching for info on the web, but all the pages
    that I can find point to
    http://www.z3roadster.net/dreamweaver/.
    This address does not exist and the domain (www.z3roadster.net)
    comes up with an asp.net error page.
    Also, is it necessary for the site to use frames for this
    Javascript/DHTML to work?

    Blim wrote:
    > Although this reveals the text in the design window, if
    I try and click on the
    > text to edit it, it disappears. I can find the text in
    the code window, and I
    > could edit it there, but I have a lot of changes to make
    and I would prefer to
    > make them with some visual feedback of the formatting.
    Does anybody know if
    > this is possible?
    Now way for anyone to know for sure without a link to your
    page to see what code it uses. One suggestion would be to copy and
    paste the text into another document make the necessary edits and
    then paste it back into the original document.
    > Also, is it necessary for the site to use frames for
    this Javascript/DHTML to
    > work?
    Unless the script you are talking about uses a iframe within
    the divs to create the scrollable area (which is doesn't seem to do
    if you can see the text of the scrollable area in the code), then
    it seems from your description that it should work, but only way to
    tell is for you to pull the frames out.
    Danilo Celic
    | Extending Knowledge Daily :
    http://CommunityMX.com/
    | Adobe Community Expert

  • Script window: vanished

    What happened to the script window ? (top menu, in Photoshop CS6). It was still there in Photoshop CS5.
    I am using Photoshop CS6 extended.
    Thank you to answer.

    Actions and Scripts in Photoshop are two different things.  That was the source of the confusion.
    What is the real problem?  That the actions you created in a prior version of Photoshop aren't in the panel in the new version?  You have to save your custom Actions sets in .atn files, then load them yourself.
    Nothing's stopping you from clicking the Actions entry of the Window menu to show the Actions panel.
    Edit:  Never mind - I missed reading the text from you second-to-last post.
    -Noel

  • Cursor in script window

    Has anyone else had this problem? When I'm typing a script,
    the cursor gets further and further away from the text. When I go
    to select a section of the text, It doesn't select what I expect it
    to, but selects something earlier in the sentence. Also the text
    kind of looks crappy in the window. Almost like it's squeezed in.
    Are there any solutions to fixing this or is there an update
    coming? This is making it more difficult to do scripting.

    I have read on other forums that I can separate the script
    window and this will solve the problem. I can't seem to figure out
    how to make the script window a single floating group of it's own.
    Any ideas?

  • Read Only Display of Radio group and Text area with counter not working

    Hello,
    I am using Apex 3.2, with 10g for the database
    I have this form, with fields that will set to read only when status = 'closed'
    All of the fields display as read only except for 2. I cannot figure out why this is not working correctly.
    1st field is Issues that is a text area with character counter, with a sql query behind it, that is set to null unless the query is pulling in the data.
    2nd field is Status which is a radio group that will not display as read only when status = 'closed'
    I have other fields on the form with the same format and they change to read only when the status = 'closed', I have even copied the pl/sql expression from one field to these fields and it still doesn't work correctly. I have also tried javascript for an on load event, which works, but once I click on the save button, it disables all of the page items, which works correctly, but I purposely forget to enter information, to make sure the validations are firing correctly, which it does, but the script disables everything, not allowing me to correct the errors. The javascript is firing on the on page load event.
    Any help on this is greatly appreciated.
    Mary

    Dung,
    That API seems to have a bug, it returns true/false/null, so you could use 'return not nvl(htmldb_util.current_user_in_group(p_group_name => 'APP Admin'),false)' to get a false value.
    Unfortunately there's another problem: using the read-only attributes for checkbox or radiogroup item makes them hidden. My suggestion would be to create another item that has disabled="disabled" in the HTML Form Element attribute in the item definition and display that item or the non-disabled item alternately, using conditions based on the current_user_in_group logic.
    Scott

  • Issue with rightclicking in a text area which uses Squiggly

    Hi,
    I have found an issue with using squiggly in a TextArea component.
    I was able to simulate the same in the demo url . http://labs.adobe.com/technologies/squiggly/demo/#
    The issue is when I enter a random text like "aaaaaaaaaaaaaaaaaaaaaaaaaaaa" and then when I do a right click on the text area,
    I get an exception as shown below.
    TypeError: Error #1010: A term is undefined and has no  properties.
    at  com.adobe.linguistics.spelling.core::SuggestionManager/nsuggest()[C:\squiggly\esg\squiggl y\main\AdobeSpellingEngine\src\com\adobe\linguistics\spelling\core\SuggestionManager.as:20 1]
    at  com.adobe.linguistics.spelling.core::SquigglyEngine/suggest()[C:\squiggly\esg\squiggly\ma in\AdobeSpellingEngine\src\com\adobe\linguistics\spelling\core\SquigglyEngine.as:285]
    at  com.adobe.linguistics.spelling::SpellChecker/getSuggestions()[C:\squiggly\esg\squiggly\ma in\AdobeSpellingEngine\src\com\adobe\linguistics\spelling\SpellChecker.as:145]
    at  com.adobe.linguistics.spelling.ui::HaloWordProcessor/getSuggestionsAtPoint()[C:\squiggly\ esg\squiggly\main\AdobeSpellingUI\src\com\adobe\linguistics\spelling\ui\HaloWordProcessor. as:49]
    at  com.adobe.linguistics.spelling.ui::SpellingContextMenu/handleContextMenuSelect()[C:\squig gly\esg\squiggly\main\AdobeSpellingUI\src\com\adobe\linguistics\spelling\ui\SpellingContex tMenu.as:124]
    So is there any fix for the above error or a workaround for this.
    This has been filed as bug in an application I am working on.
    regards,
    Anup Francis

    Thank you for reporting this issue.
    I was unable to reproduce this problem under the following configurations:
    Mac OSX 10.6.3, Flash 10.0.42.34, Firefox 3.6.3
    Windows XP, Flash 10.0.45.2, IE 8.0.6001
    Windows XP, Flash 10.1.53.21, Firefox 3.6.3
    Could you provide more details about the software configurations you have that reproduces this problem?
    Also, is there a specific location you click in the TextArea?  On the word?  On white space?
    Thanks,
    - Bruce, Adobe

  • Script Window in display mode

    Hi All,
    I am working on modification of the dunning report script (SAP VERSION IS 4.6C) . My requirment is to add few more lines in the address window in the script. The address window is VARIABLE type. When I am trying to do change in the change mode of the script the window parameters are coming in display mode . I want to increase the height of the window. As the dimensions are in display mode I am not able to change.
    please guide me.
    Thanks ,
    Vengal rao

    Hi Vengalrao,
    The Create, Change and Delete option in Zform are coming disabled because the original language in which the form was copied or created would be different than the language in which you are trying to edit.
    You can only make changes in elements in forms original language only.
    Revert in case i am not clear.
    Thanks,
    Daya.

Maybe you are looking for

  • Prevent creation of PO  and not PR

    Hi, Requirement is to prevent PO creation for a material type for a particular status and not Purchase requisition. By making Purchasing message u201CBu201D for a particular material status, it gives error message while creation of PO and purchase re

  • Problem with Exporting/Stacking in Lightroom 5.2

    I have used stacks in Lightroom for a long time but I am now having a problem. My typical workflow is to process RAW images in the Develop Module then Export them as JPG files. I choose "export to same folder as original" and I check "add to this cat

  • Just a quick question re my broadband speed.

    Hi (again) The advertised speed (from BT's choose for package page) for my line is 8.5Mb-13Mb, but I only ever have 5meg max (on a good day)? Just wondered. Mazz Solved! Go to Solution.

  • Double copies of files

    I find that if i ope a cd rom on my mac so that there are eg 15 mp3 files click on select all and then drag them into my itunes window then it makes two copies of each one - any ideas why?

  • CME 4.0 GUI

    I have a 1700 running CME 4.0...i followed the basic steps of setting up the GUI, but when i go to http://ip/ccme.html and login i get a blank white page and thats it....any ideas?? Thanks in advance