How to find bounds of textcolumn

Hello ,
can anybody tell me ,how to find bounds of textcolumn.

Text columns don't have a geometricBounds property, so you have to calculate that yourself. Take the bounds of the text frame, check the number of columns (myTextFrame.textFramePreferences.textColumnCount) and the gutter width ((myTextFrame.textFramePreferences.textColumnGutter). Then you can work out the bounds of a text column.
Peter

Similar Messages

  • How to get bounds of a component in FreeDesign layout

    When I try to get bounds of a component that is inside JPanel with FreeDesign layout, I get (0,0,0,0)!
    How can I find out current bounds of those components?

    When I add a component on JPanel with FreeDesign layout (I use NetBeans GUI editor to do it), in generated code I find org.jdesktop.layout.GroupLayout with some HorizontalGroup and VerticalGroup components, and no bounds are ever set!!! When I start the application, a component is shown on JPanel, and definitely bounds are not 0,0,0,0! The components are stretched over window, and everything looks just as I set in GUI editor. A problem is that in runtime I need to know bounds of a component that is showed on screen. A method getBounds() returns (0,0,0,0), so I think that it is not appropriate for this layout.
    So, my question remains: How to find out bounds of a component in FreeDesign layout!
    Thanks!
    Message was edited by:
    mmilic

  • How to find out if two JComponents overlap?

    I wanted to create very simple game, another version of arcanoid (or krakout) where player tries to hit bouncing ball with paddle so the ball will break the wall made of small bricks. so far came up with an idea that paddle will be JComponent controlled by mouse, ball will be also JComponent controlled by mouse and after a while got it ready and coded. before i'll go to bricks (which i'm also planning to do as JComponents :) i wanted to know
    - how to find out when the paddle and the bouncing ball hit each other and if theres any method that returns boolean (or sth..) when any part of those components overlap so i can change the direction of the ball and take particular bricks off the screen (or will have to do it manually somehow..)?
    - also wanted to know if my thinking is correct and douing it with separate classes, having the ball as a thread (changing its .location(..) on the way to move the ball) ,and controlling paddle (another class) just by MouseMotionListener is correct way to do it or there is some other standard aproach to that kind of a program
    - how to control if mouse is leaving particular JPanel so i can have user stopped before and keep him inside of that Jpanel, unless he will press particular button or do something
    thanks in advance for any help and sorry for probably quite confuzing explanation

    Well, yes, because this solution uses the bounds of the JComponent. If you want more complicated shapes, you could define a polygon for instance (java.awt.Polygon) and use it's intersects method, but then the other shape would still need to be a rectangle.
    Other options include GeneralPath class and Area class, this would not limit you to rectangles. With the first class you can also draw arbitrary shapes. With the second you can do intersections, unions etc.
    Have a look at http://java.sun.com/docs/books/tutorial/2d/TOC.html#display (Java2d )
    Mind you, this is more complicated!
    Rene'

  • How to find out the rows inserted between a time period.

    Hi,
    Please help me to solve this.
    Table - emp.
    Colmns - empno(Primary Key),ename, mgr
    How to find out the rows inserted between a time period.
    For eg:- Between 02-Oct-2006 1 PM and 03-Oct-2006 2 PM.
    regards,
    Mathew.

    Hi,
    Maybe work:
    For each row, ORA_ROWSCN returns the conservative upper bound system change number (SCN) of the most recent change to the row. This pseudocolumn is useful for determining approximately when a row was last updated. It is not absolutely precise, because Oracle tracks SCNs by transaction committed for the block in which the row resides
    e.g.:
    SGMS@ORACLE10> create table test(cod number);
    Table created.
    SGMS@ORACLE10> insert into test values (1);
    1 row created.
    SGMS@ORACLE10> insert into test values (2);
    1 row created.
    SGMS@ORACLE10> commit;
    Commit complete.
    SGMS@ORACLE10> insert into test values (3);
    1 row created.
    SGMS@ORACLE10> commit;
    Commit complete.
    SGMS@ORACLE10> select SCN_TO_TIMESTAMP(ora_rowscn),ora_rowscn,cod from test;
    SCN_TO_TIMESTAMP(ORA_ROWSCN)       ORA_ROWSCN        COD
    06/11/06 08:56:56,000000000         727707205          1
    06/11/06 08:56:56,000000000         727707205          2
    06/11/06 08:57:05,000000000         727707210          3Cheers

  • How to find Material Document respect to incoming excise invoices?

    When stock is transfered from one plant to another,
    in sending plant, material document is created, with respect to this material document out bound delivery is created further out bound excise invoices.
    In receiving plant when the incoming stock reached the plant with incoming excise
    invoice, material document is created .
    how to find the this receiving plant material document with respect to incoming excise invoice.?
    how to get the receiving plant material documents with respect to sending plant material documents?

    when  the material is transferred from the one plant to another.
    before going to transfer the material.
    one material document is created
    with respect to multiple item  of material document delivery documents created.
    for every delivery one invoice is generated.
    when the stock is reached to plant with invoice
    with respect to this invoice one material document is created for quality check.
    I this case we may have multiple invoices may have the multiple material documents in receiving plant .
    how to find for which excise invoice it is creating material document in receiving plant?

  • How to use bounding theme with jdbc theme

    Hello
    I'm using oracle maps javascript API to locate geometry with jdbc theme based foi, so how to use bounding theme with jdbc theme? Give me help, thanks.

    Hi,
    You can find some information & code samples at this link :-
    http://download-west.oracle.com/docs/cd/B19306_01/java.102/b14355/xadistra.htm#g1077100
    Regards,
    Sandeep

  • Finding bounds of nested clipping paths...

    This topic has been touched on before, muppet & sonic have pointed me in the right direction, but I'm stuck right now....
    Seeing as how "saveMultipleArtboards = false" is broken in CS4, and scripting any kind of epsSave results in the artboard size being the bounding box, I am trying to see if I can find out if the "visible to the eye" bounds of artwork exceed the artboard size.
    I can easily find non-clipped objects hanging outside the artboard by comparing the document's visible bounds to the artboard size.
    Likewise the "visible to the eye" bounds of clipped objects :
    var docRef = app.activeDocument;
    docRef.rulerOrigin = [0,0];
    ////Get size of artboard
    var myDocsizeArray = [0,0,docRef.width,docRef.height]
    ////Check for items on page
    if(docRef.pageItems.length != 0){
    /////Find out if top item is clipping mask
    if(docRef.pageItems[0].typename == "GroupItem"){
    if(docRef.pageItems[0].pathItems[0].clipping == true){
    ////Compare its bounds to doc bounds
    var myClipArray = docRef.pageItems[0].pathItems[0].visibleBounds
    if((myClipArray[1] >  myDocsizeArray[3]) || (myClipArray[2] >  myDocsizeArray[2]) || (myClipArray[0] < 0) || (myClipArray[3] < 0)){
    alert("Outside of artboard")
    However, this doesn't work if clipping paths are part of a nested groups. Is there a way to see if a clipping path's parent group is within bounds, or parent's parent group etc. is within bounds. I need to find the topmost clipping path that trumps all the others in any nested group.
    Is that what recursive functions are for? ,,,,,,,,,,,
    Something that can keep looking in a loop within itself?  Very instrospective!
    thx

    Does this help? I use these to position and find bounds based upon what is visible.
    function getRealVisibleBounds(grp) {
         var outerBounds = [];
         for(var i = grp.pageItems.length - 1; i >= 0;i--)  {
              var bounds = [];
              if(grp.pageItems[i].typename == 'GroupItem') {
                   bounds =  getRealVisibleBounds(grp.pageItems[i]);
              else if((grp.pageItems[i].typename == 'PathItem' || grp.pageItems[i].typename == 'CompoundPathItem')
                   && (grp.pageItems[i].clipping || !grp.clipped)) {
                   bounds = grp.pageItems[i].visibleBounds;
              if (bounds.length > 0) {
                   outerBounds = maxBounds(outerBounds,bounds);
         return (outerBounds.length == 0) ? null : outerBounds;
    function maxBounds(ary1,ary2) {
         var res = [];
         if(ary1.length == 0)
              res = ary2;
         else if(ary2.length == 0)
              res = ary1;
         else {
              res[0] = Math.min(ary1[0],ary2[0]);
              res[1] = Math.max(ary1[1],ary2[1]);
              res[2] = Math.max(ary1[2],ary2[2]);
              res[3] = Math.min(ary1[3],ary2[3]);
         return res;
    function positionVisible(grp,x,y)
         var bounds = getRealVisibleBounds(grp);
         var newX = x + (grp.left - bounds[0]);
         var newY = y + (grp.top - bounds[1]);
         grp.position = [newX,newY];

  • How to find primary monitor

    Hi,
    I need to find whether frame is on Primary monitor or not. How to find out?
    Regards
    Ketan

    I am not really sure but I just did some tests and on my machine it looks as if the primary monitor is the one whose bounds start at 0,0.
    Of course I only tested with an "extended desktop" setting, where my desktop is spanned across 2 monitors. But in the case where both monitors show the same stuff it shouldn't really matter, right?
    import java.awt.GraphicsConfiguration;
    import java.awt.GraphicsDevice;
    import java.awt.GraphicsEnvironment;
    import java.awt.GridLayout;
    import java.awt.Rectangle;
    import javax.swing.JFrame;
    import javax.swing.JLabel;
    public class PrimaryMonitor
      public static void main(String[] args)
        GraphicsEnvironment graphicsEnvironment = GraphicsEnvironment.getLocalGraphicsEnvironment();
        GraphicsDevice[] screenDevices = graphicsEnvironment.getScreenDevices();
        for(GraphicsDevice screenDevice : screenDevices)
          System.out.println(screenDevice + ", ID=" + screenDevice.getIDstring());
          GraphicsConfiguration screenConfiguration = screenDevice.getDefaultConfiguration();
          Rectangle screenBounds = screenConfiguration.getBounds();
          System.out.println(screenBounds);
          JFrame frame = new JFrame(screenDevice.getIDstring());
          frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
          frame.setLayout(new GridLayout(0, 1));
          frame.add(new JLabel(screenDevice.getIDstring()));
          frame.add(new JLabel("" + screenBounds));
          if(screenBounds.x == 0)
            frame.add(new JLabel("Primary?"));
          frame.setBounds(screenBounds.x, screenBounds.y, 600, 200);
          frame.setVisible(true);
    }

  • How to find out the overlapping object?

    Is it possible to find out wheather one pathItem which not in horizontal and vertical position be overlaped or touched any other items like pathitems,textframes etc. in illustrator cs3 active document.
    I got the top, left, right and bottom values of the bounding box for every items. From that i got the overlap of bounding boxes. But i don't know how to find out one pathItem overlaped (or) touched any other items. Kindly advice me the possibilities. I have attached the sample file for review.
    Thanks in advance.

    You always can copy your art and implement "Intersect" in Pathfinder
    using sAIActionManager->PlayActionEvent(...).
    Then check if remained art  != nil.

  • Discoverer Report: How to find Business Area name from Report Name.

    Hi
    I opened a report in Disco Desktop 4 -> Resonsibiolity --> Report Name.
    So I know Report name but don’t know which Business Area it belongs to.
    How to find Business Area Name from Report Name?
    Cheers
    Vijay

    Hi,
    There is no relationship between reports and business areas. Each report can be built from many folders. Each folder can be in many business areas.
    However you can try the following SQL which may give you the result you want for an v5 EUL. You will have to modify for Discoverer 4 EUL:
    select distinct doc_name, obj.obj_name folder_name, bas.ba_name
    from eul_us.eul5_documents doc
    , eul_us.eul5_elem_xrefs xref
    , eul_us.eul5_expressions exp
    , eul_us.eul5_objs obj
    , eul_us.eul5_ba_obj_links bol
    , eul_us.eul5_bas bas
    where xref.ex_from_id = doc.doc_id
    and doc.doc_name = &your_report
    and xref.ex_to_id = exp.exp_id
    and obj.obj_id = exp.it_obj_id
    and bol.bol_obj_id = obj.obj_id
    and bas.ba_id = bol.bol_ba_id
    Rod West

  • How to find a specific word in sentence in each line?

    How to find a specific word in sentence in each line and output will show start from the beginning from specific word plus with small description from each sentence?
    For example: I need to find a "+Wednesday+" and "+Thursday+" word in each sentence by line by line from "myfile.txt".
    Go ballet class next Wednesday.
    On the Wednesday is going to swim class.
    We have a meeting on Thursday at Panda's.
    Then it will show the output:
    Wednesday : ballet class
    Wednesday : swim class
    Thursday: meeting at Panda's
    I am going to figure out in Java console to read from a file for specific word from each line and how to make it output in correct way. I know already to make input/file codes.

    I got it and understand much better. Thank you very much. There is a problem with it because I knew how to make
    a specific word in sentence but how I should make Output for specific word and some words from sentence.
    For example:
    Input:
    +"On Thursday go to ballet class"+
    +"Swim class on Friday one time a month at 2 p.m."+
    I used the codes for that:
    class FindSchedule{
         String firstline = "On Thursday go to ballet class ";
         String secondline = "Swim class on Friday one time a month ";
         FindSchedule(){
              System.out.println(firstline + findTheIndex("Thursday", firstline));
              System.out.println(secondline + findTheIndex("Friday", secondline));
         public int findTheIndex(String word, String sentence){
              int index;
              index = sentence.indexOf(word);
              return index;
         public static void main (String[] args){
              new FindSchedule();
    }The output will be:
    Thursday: ballet class
    Friday: 14:00 swim class one time a week
    Notice that time is changing in output complete different from input.
    I need to find out how to extract some words from each sentence for output. Do you know how to do it?

  • How to find out the user-exits?

    hi.
    how to find out the user-exits?
    regards
    eswar.

    Hi,
    *& Report  ZEXITFINDER
    *report  zexitfinder.
    *& Enter the transaction code that you want to search through in order
    *& to find which Standard SAP User Exits exists.
    *& Tables
    tables : tstc, "SAP Transaction Codes
    tadir, "Directory of Repository Objects
    modsapt, "SAP Enhancements - Short Texts
    modact, "Modifications
    trdir, "System table TRDIR
    tfdir, "Function Module
    enlfdir, "Additional Attributes for Function Modules
    tstct. "Transaction Code Texts
    *& Variables
    data : jtab like tadir occurs 0 with header line.
    data : field1(30).
    data : v_devclass like tadir-devclass.
    *& Selection Screen Parameters
    selection-screen begin of block a01 with frame title text-001.
    selection-screen skip.
    parameters : p_tcode like tstc-tcode obligatory.
    selection-screen skip.
    selection-screen end of block a01.
    *& Start of main program
    start-of-selection.
    Validate Transaction Code
    select single * from tstc
    where tcode eq p_tcode.
    Find Repository Objects for transaction code
    if sy-subrc eq 0.
    select single * from tadir
    where pgmid = 'R3TR'
    and object = 'PROG'
    and obj_name = tstc-pgmna.
    move : tadir-devclass to v_devclass.
    if sy-subrc ne 0.
    select single * from trdir
    where name = tstc-pgmna.
    if trdir-subc eq 'F'.
    select single * from tfdir
    where pname = tstc-pgmna.
    select single * from enlfdir
    where funcname = tfdir-funcname.
    select single * from tadir
    where pgmid = 'R3TR'
    and object = 'FUGR'
    and obj_name = enlfdir-area.
    move : tadir-devclass to v_devclass.
    endif.
    endif.
    Find SAP Modifactions
    select * from tadir
    into table jtab
    where pgmid = 'R3TR'
    and object = 'SMOD'
    and devclass = v_devclass.
    select single * from tstct
    where sprsl eq sy-langu
    and tcode eq p_tcode.
    format color col_positive intensified off.
    write:/(19) 'Transaction Code - ',
    20(20) p_tcode,
    45(50) tstct-ttext.
    skip.
    if not jtab[] is initial.
    write:/(95) sy-uline.
    format color col_heading intensified on.
    write:/1 sy-vline,
    2 'Exit Name',
    21 sy-vline ,
    22 'Description',
    95 sy-vline.
    write:/(95) sy-uline.
    loop at jtab.
    select single * from modsapt
    where sprsl = sy-langu and
    name = jtab-obj_name.
    format color col_normal intensified off.
    write:/1 sy-vline,
    2 jtab-obj_name hotspot on,
    21 sy-vline ,
    22 modsapt-modtext,
    95 sy-vline.
    endloop.
    write:/(95) sy-uline.
    describe table jtab.
    skip.
    format color col_total intensified on.
    write:/ 'No of Exits:' , sy-tfill.
    else.
    format color col_negative intensified on.
    write:/(95) 'No User Exit exists'.
    endif.
    else.
    format color col_negative intensified on.
    write:/(95) 'Transaction Code Does Not Exist'.
    endif.
    Take the user to SMOD for the Exit that was selected.
    at line-selection.
    get cursor field field1.
    check field1(4) eq 'JTAB'.
    set parameter id 'MON' field sy-lisel+1(10).
    call transaction 'SMOD' and skip first screen.
    Regards

  • How to find out the Transactions used per month & the USER who used that

    Hi,
    1)How to find out the Transactions used per month & the USER who used that?
    2)and can i get the above same for minimum 20 month?
    System : SAP- Enterprise Core Component.

    You can use my program...
    *& Report  Z_ABAP_TCODE_MONITOR
    *****&  Program Type          : Report                                 *
    *****&  Title                 : Z_ABAP_TCODE_MONITOR                   *
    *****&  Transaction code      : ZTCODE_USAGE                           *
    *****&  Developer name        : Shailendra Kolakaluri                  *
    *****&  Deveopment start date : 26 th Dec 2011                         *
    *****&  Development Package   : ZDEV                                   *
    *****&  Transport No          : DEVK906086                                       *
    *****&  Program Description   : This program is to display
    *List all tcodes executed during previous day.
    *& Show the number of users executing tcodes
    *& Modification history
    REPORT  Z_ABAP_TCODE_MONITOR.
    *& List all tcodes executed during previous day.
    *& Show the number of users executing tcodes
    TYPE-POOLS : slis.
    DATA: ind TYPE i,
          fcat TYPE slis_t_fieldcat_alv WITH HEADER LINE,
          layout TYPE slis_layout_alv,
          variant TYPE disvariant,
          events  TYPE slis_t_event WITH HEADER LINE,
          heading TYPE slis_t_listheader WITH HEADER LINE.
    *REPORT  z_report_usage.
    TYPES: BEGIN OF zusertcode,
      date   TYPE swncdatum,
      user   TYPE swncuname,
      mandt     TYPE swncmandt,
      tcode     TYPE swnctcode,
      report TYPE swncreportname,
      count     TYPE swncshcnt,
    END OF zusertcode.
    *data   : date type n.
    DATA: t_usertcode  TYPE swnc_t_aggusertcode,
          wa_usertcode TYPE swncaggusertcode,
          wa           TYPE zusertcode,
          t_ut         TYPE STANDARD TABLE OF zusertcode,
          wa_result    TYPE zusertcode,
          t_result     TYPE STANDARD TABLE OF zusertcode.
    PARAMETER: month TYPE dats DEFAULT sy-datum.
    *PARAMETER: date TYPE dats.
    *select-options : username for wa_usertcode-account.
    START-OF-SELECTION.
    PERFORM get_data.
    PERFORM get_fieldcatalog.
      PERFORM set_layout.
    PERFORM get_event.
    PERFORM get_comment.
      PERFORM display_data.
    FORM get_data .
    *date = sy-datum - 2 .
    After start-of-selection add this line (parameter Month required 01 as day).
      concatenate month+0(6) '01' into month.
      CALL FUNCTION 'SWNC_COLLECTOR_GET_AGGREGATES'
        EXPORTING
          component     = 'TOTAL'
          ASSIGNDSYS    = 'DEV'
          periodtype    = 'M'
          periodstrt    = month
        TABLES
          usertcode     = t_usertcode
        EXCEPTIONS
          no_data_found = 1
          OTHERS        = 2.
      wa-date  = month.
    *wa-date  = date.
      wa-mandt = sy-mandt.
    wa_usertcode-account = username.
      LOOP AT t_usertcode INTO wa_usertcode.
        wa-user = wa_usertcode-account.
        IF wa_usertcode-entry_id+72 = 'T'.
          wa-tcode  = wa_usertcode-entry_id.
          wa-report = space.
        ELSE.
          wa-tcode  = space.
          wa-report = wa_usertcode-entry_id.
        ENDIF.
        COLLECT wa INTO t_ut.
      ENDLOOP.
      SORT t_ut BY report ASCENDING.
      CLEAR: wa, wa_result.
    endform.
    FORM get_fieldcatalog .
    fcat-tabname     = 't_ut'.
    fcat-fieldname   = 'DATE'.
    fcat-seltext_l   = 'Date'.
    fcat-key         = 'X'.
    APPEND fcat.
      CLEAR fcat.
      fcat-tabname     = 't_ut'.
      fcat-fieldname   = 'MANDT'.
      fcat-seltext_l   = 'Client'.
      fcat-key         = 'X'.
      APPEND fcat.
      CLEAR fcat.
      fcat-tabname     = 't_ut'.
      fcat-fieldname   = 'USER'.
      fcat-seltext_l   = 'User Name'.
      fcat-key         = 'X'.
      APPEND fcat.
      CLEAR fcat.
      fcat-tabname     = 't_ut'.
      fcat-fieldname   = 'TCODE'.
      fcat-seltext_l   = 'Transaction Code'.
      fcat-key         = 'X'.
      APPEND fcat.
    ENDFORM.
    *&      Form  SET_LAYOUT
          text
    -->  p1        text
    <--  p2        text
    FORM set_layout .
      layout-colwidth_optimize = 'X'.
    ENDFORM.                    " SET_LAYOUT
    *&      Form  GET_EVENT
          text
    -->  p1        text
    <--  p2        text
    *FORM get_event .
    events-name = slis_ev_top_of_page.
    events-form = 'TOP_OF_PAGE'.
    APPEND events.
    *ENDFORM.                    " GET_EVENT
    **&      Form  GET_COMMENT
          text
    -->  p1        text
    <--  p2        text
    *FORM get_comment .
    DATA: text(30).
    text = 'Billing Report'.
    heading-typ = 'H'.
    heading-info = text.
    APPEND heading.
    *ENDFORM.                    " GET_COMMENT
    **&      Form  top_of_page
          text
    -->  p1        text
    <--  p2        text
    *FORM top_of_page .
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
       EXPORTING
         it_list_commentary       = heading[]
      I_LOGO                   =
      I_END_OF_LIST_GRID       =
    *ENDFORM.                    " top_of_page
    *&      Form  DISPLAY_DATA
          text
    -->  p1        text
    <--  p2        text
    FORM display_data .
      sort t_ut[].
    DELETE ADJACENT DUPLICATES FROM t_ut[] COMPARING ALL FIELDS.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program = sy-cprog
          is_layout          = layout
          it_fieldcat        = fcat[]
          i_save             = 'A'
          is_variant         = variant
          it_events          = events[]
        TABLES
          t_outtab           = t_ut
        EXCEPTIONS
          program_error      = 1
          OTHERS             = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    ENDFORM.                    " DISPLAY_DATA

  • How to find out the person who did a transport.

    How to find out the person who did a transport.
    There are 3 basis admins in our Org.
    so is there a way of tracing out , who did what transport.
    Regards,

    - Goto import Overview (STMS)
    - Import Queue
    - Select DEV req (goto Import History)
    - Edit - Display More
    It will show the user who did the transport
    Rgds

  • How to find out the user who has created  a new field in the custom table.

    How to find out the user details who has created  a new field in the custom table.
    Thanks,
    Joan

    Hi Jesudasan ,
    You can know the user details with version management.Please find the
    below procedure to know.
    Go to table->Utilities tab->version->Version management->Compare the previous one .
    Hope this solves the issue,Let me know if you have any issues.
    Thanks,
    Rajani

Maybe you are looking for