Getting exact margin of Label border to Text offset

In my application I need to align several differently-sized
Labels to the left side. If I align to the X-position, the larger
labels are positioned somewhat to the right.
I need to know how to measure the difference in x-position of
the Label, and the actual position of the text - so far, I found
nothing!
Does anybody have a hint where to look?
TIA,
Bart Guijt

You could draw to a bitmap the exact same size of the
textfield, and then use getColorBoundsRect() to get actual pixel
values. A hack, but it should work.

Similar Messages

  • How to get exact match when working with Oracle Text?

    Hi,
    I'm running Oracle9i Database R2.
    I would like to know how do I get exact match when working with Oracle Text.
    DROP TABLE T_TEST_1;
    CREATE TABLE T_TEST_1 (text VARCHAR2(30));
    INSERT INTO T_TEST_1 VALUES('Management');
    INSERT INTO T_TEST_1 VALUES('Busines Management Practice');
    INSERT INTO T_TEST_1 VALUES('Human Resource Management');
    COMMIT;
    DROP INDEX T_TEST_1;
    CREATE INDEX T_TEST_1_IDX ON T_TEST_1(text) INDEXTYPE IS CTXSYS.CONTEXT;
    SELECT * FROM T_TEST_1 WHERE CONTAINS(text, 'Management')>0;
    The above query will return 3 rows. How do I make Oracle Text to return me only the first row - which is exact match because sometimes my users need to look for exact match term.
    Please advise.
    Regards,
    Jap.

    But I would like to utilize the Oracle Text index. Don't know your db version, but if you slightly redefine your index you can achieve this (at least on my 11g instance) :
    SQL> create table t_test_1 (text varchar2(30))
      2  /
    Table created.
    SQL> insert into t_test_1 values ('Management')
      2  /
    1 row created.
    SQL> insert into t_test_1 values ('Busines Management Practice')
      2  /
    1 row created.
    SQL> insert into t_test_1 values ('Human Resource Management')
      2  /
    1 row created.
    SQL>
    SQL> create index t_test_1_idx on t_test_1(text) indextype is ctxsys.context filter by text
      2  /
    Index created.
    SQL> set autotrace on explain
    SQL>
    SQL> select text, score (1)
      2    from t_test_1
      3   where contains (text, 'Management and sdata(text="Management")', 1) > 0
      4  /
    TEXT                             SCORE(1)
    Management                              3
    Execution Plan
    Plan hash value: 4163886076
    | Id  | Operation                   | Name         | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT            |              |     1 |    29 |     4   (0)| 00:00:01 |
    |   1 |  TABLE ACCESS BY INDEX ROWID| T_TEST_1     |     1 |    29 |     4   (0)| 00:00:01 |
    |*  2 |   DOMAIN INDEX              | T_TEST_1_IDX |       |       |     4   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       2 - access("CTXSYS"."CONTAINS"("TEXT",'Management and
                  sdata(text="Management")',1)>0)
    Note
       - dynamic sampling used for this statementJust read that you indeed mentioned your db version in your first post.
    Not sure though if above method is already available in 9i ...
    Message was edited by:
    michaels

  • IBooks Author: How do you get the inset margins applied to the caption text of gallery widgets to preview correctly on an iPad?

    Currently the inset margins I set for caption text in the gallery widget resets to zero when previewed on different iPads. These are galleries with different images and the captions are set to “individual caption per image” in the interaction panel.
    BUT the inset margins will preview correctly if the gallery caption is set to “same caption for all images” in the widget interactions panel. How does one go about fixing this in iBooks Author? Would love to hear others advice or suggestions or work arounds. Thanks!

    I found this article that shows the folder we are looking for is here --
    ~/Library/Containers/com.apple.iBooksX/Data/Documents/AEAnnotation/
    per http://mjtsai.com/blog/2013/11/06/the-problem-with-ibooks/ and http://computers.tutsplus.com/tutorials/beyond-highlighting-how-to-get-the-most- from-your-annotations--cms-20013
    So I opened the files in TextWrangler to search for a word I know I highlighted in a particular book.  That helped me identify the correct file for the book I am concerned with.  I did a Time Machine restore of the file and got my notes back the way they were.

  • IBooks Author: How do you get the inset margins applied to the caption text of gallery widgets to preview correctly?

    Currently the inset margins I set for caption text in the gallery widget reset to zero when previewed on different iPads. These galleries have multiple images and the captions are set to "individual caption per image" on the widget interaction panel. BUT the inset margins preview correctly if the gallery caption is set to "same caption for all images" in the gallery widget interaction panel. How does one fix this in iBooks Author? Would appreciate any advice or work arounds or suggestions.
    Thanks!

    The arrows don't show up on the iPad, they are only to aid navigation within iBA. You can use boxes in the background to frame your galleries (as the background is off). I believe it's also possible to change the colour of the dots beneath the gallery too, although I forget how to do that right now.
    About Apple's rigid UX – I agree that it can be frustrating. Apple intended iBA to be used by everyone, and the sort of design options and customisability we might want may confuse the less experienced user. Apple also wanted the UI for every book to be the same – from the point of view of the new user, once you've used one iBA ebook (or iBook, I'm not sure what Apple want us to call it), you can use them all. Otherwise end users would to get used to a slightly different UI on each book, which kind of works against the idea that ideally UI should be intuitive enough to be invisible. I can see the point in that. I have created a 'How to use' section in every iBA file I've made. It get's old quickly.
    Oh, and (you probably know this, but…) you can choose your own custom icon for audio. It's limited, as it's only a placeholder image that allows you to play an audio file, there's no ability to pause the audio or stop it once you choose the view as thumbnail choice. Something I'd like to see changed.
    Here's a link to Apple feedback page for iBA. Feel free to hammer it with your suggestions.
    https://www.apple.com/feedback/ibooks-author.html

  • I can't get rid of this blue border around my artwork after it's published to the web

    I can't get rid of this blue border around my artwork after it's published to the web

    That did not work.
    Here's where I put it. The blue bordeer still show up around the large rectangular image.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Ray Bros., Inc.</title>
    <style type="text/css">
    @import url("PopupMenuC.css");
    @import url("PopupMenuB.css");
    @import url("PopupMenu1.css");
    body {
              margin-left: 00px;
              margin-top: 00px;
              margin-right: 00px;
              margin-bottom: 00px;
              text-align: center;
    a img {border:none}
    .Arial {
              font-family: Arial, Helvetica, sans-serif;
    .Arial {
              font-size: 10px;
    .Arial {
              font-size: 12px;
    .Arial .Arial {
              font-size: 14px;
    </style>
    <script language="JavaScript1.2" type="text/javascript" src="mm_css_menu.js"></script>
    </head>
    <body>
    <table width="1080" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td height="279" align="center" valign="top"><div id="FWTableContainer1818523225"> <img name="PopupMenuC" src="PopupMenuC.jpg" width="1082" height="279" id="PopupMenuC" usemap="#m_PopupMenuC" alt="" />
          <map name="m_PopupMenuC" id="m_PopupMenuC">
            <area shape="rect" coords="899,240,1064,265" href="index-new.html" alt="" />
            <area shape="rect" coords="679,240,844,265" href="index-new.html" alt="" />
            <area shape="rect" coords="460,240,625,265" href="javascript:;" alt="" onmouseout="MM_menuStartTimeout(1000);"  onmouseover="MM_menuShowMenu('MMMenuContainer0525123758_0', 'MMMenu0525123758_0',485,265,'PopupMenuC');"  />
            <area shape="rect" coords="241,240,406,265" href="javascript:;" alt="" onmouseout="MM_menuStartTimeout(1000);"  onmouseover="MM_menuShowMenu('MMMenuContainer0524224504_0', 'MMMenu0524224504_0',262,265,'PopupMenuC');"  />
            <area shape="rect" coords="22,240,187,265" href="javascript:;" alt="" onmouseout="MM_menuStartTimeout(1000);"  onmouseover="MM_menuShowMenu('MMMenuContainer0524221503_1', 'MMMenu0524221503_1',46,265,'PopupMenuC');"  />
          </map>
          <div id="MMMenuContainer0525123758_0">
            <div id="MMMenu0525123758_0" onmouseout="MM_menuStartTimeout(1000);" onmouseover="MM_menuResetTimeout();"> <a href="index-new.html" id="MMMenu0525123758_0_Item_0" class="MMMIFVStyleMMMenu0525123758_0" onmouseover="MM_menuOverMenuItem('MMMenu0525123758_0');"> RBI-NS100 </a> <a href="index-new.html" id="MMMenu0525123758_0_Item_1" class="MMMIVStyleMMMenu0525123758_0" onmouseover="MM_menuOverMenuItem('MMMenu0525123758_0');"> RBI-M100 </a> <a href="index-new.html" id="MMMenu0525123758_0_Item_2" class="MMMIVStyleMMMenu0525123758_0" onmouseover="MM_menuOverMenuItem('MMMenu0525123758_0');"> RBI-100 </a> <a href="index-new.html" id="MMMenu0525123758_0_Item_3" class="MMMIVStyleMMMenu0525123758_0" onmouseover="MM_menuOverMenuItem('MMMenu0525123758_0');"> Color Charts </a> </div>
          </div>
          <div id="MMMenuContainer0524224504_0">
            <div id="MMMenu0524224504_0" onmouseout="MM_menuStartTimeout(1000);" onmouseover="MM_menuResetTimeout();"> <a href="index-new.html" id="MMMenu0524224504_0_Item_0" class="MMMIFVStyleMMMenu0524224504_0" onmouseover="MM_menuOverMenuItem('MMMenu0524224504_0');"> RBI-5V </a> <a href="index-new.html" id="MMMenu0524224504_0_Item_1" class="MMMIVStyleMMMenu0524224504_0" onmouseover="MM_menuOverMenuItem('MMMenu0524224504_0');"> RBI Low Profile AGG </a> <a href="index-new.html" id="MMMenu0524224504_0_Item_2" class="MMMIVStyleMMMenu0524224504_0" onmouseover="MM_menuOverMenuItem('MMMenu0524224504_0');"> Color Charts </a> </div>
          </div>
          <div id="MMMenuContainer0524221503_1">
            <div id="MMMenu0524221503_1" onmouseout="MM_menuStartTimeout(1000);" onmouseover="MM_menuResetTimeout();"> <a href="index-new.html" id="MMMenu0524221503_1_Item_0" class="MMMIFVStyleMMMenu0524221503_1" onmouseover="MM_menuOverMenuItem('MMMenu0524221503_1');"> RBI-MT240 </a> <a href="index-new.html" id="MMMenu0524221503_1_Item_1" class="MMMIVStyleMMMenu0524221503_1" onmouseover="MM_menuOverMenuItem('MMMenu0524221503_1');"> RBI-200 </a> <a href="index-new.html" id="MMMenu0524221503_1_Item_2" class="MMMIVStyleMMMenu0524221503_1" onmouseover="MM_menuOverMenuItem('MMMenu0524221503_1');"> RBI-175 </a> <a href="index-new.html" id="MMMenu0524221503_1_Item_3" class="MMMIVStyleMMMenu0524221503_1" onmouseover="MM_menuOverMenuItem('MMMenu0524221503_1');"> R-Panel </a> <a href="index-new.html" id="MMMenu0524221503_1_Item_4" class="MMMIVStyleMMMenu0524221503_1" onmouseover="MM_menuOverMenuItem('MMMenu0524221503_1');"> Color Charts </a> </div>
          </div>
        </div></td>
      </tr>
      <tr>
        <td valign="top"><p><br />
        </p></td>
      </tr>
      <tr>
        <td> </td>
      </tr>
      <tr>
        <td> </td>
      </tr>
      <tr>
        <td>...</td>
      </tr>
      <tr>
        <td> </td>
      </tr>
    </table>
    </body>
    </html>

  • How I can save an existed Table "exactly" into an Excel or a Text file?

    I am able to save from a Table into an Excel file, but I could not put in it the following:
    a)Column Headers
    b)First column should be integer
    c)The Scientific notation (supposed to be with 6 decimal point) but it shows only two decimal point
    d)In the last 3 rows, it couldn't understand --> it showed Zero's
    ***> It shows better when I changed the data.xls to data.txt ... only solved c)
    ***> You cam modify completely how to write into the Excel or Text file ... but do not change the way I write to the TABLE (I have "no choice" to keep it that way!)
    Attachments:
    Write_Table.vi ‏51 KB

    First of all, the Write to Spreadsheet File function does not create an Excel file. It creates a text file with values separated by a delimiter. Excel is capable of recognizing tabs and commas as delimiters and will convert the text into a spreadsheet.
    Most of your problems can be solved by converting Write to Spreadsheet to accept arrays of strings instead of arrays of numbers and adding the column headers to the array. You'll probably have to experiment with the Excel import function as well.
    Thye best way, however to get exactly what you want into Excel is to use ActiveX. There is an example the4 comes with LabVIEW that shows some of the basics. You can find other examples by searching the Developers Zone. NI also sells a toolkit for reading/
    writing Excel and Word files.

  • How to enable the script label of a text frames in indesign using applescript

    hi all,
    am using Indesign CS2 with applescript..
    Using script I have to open a template in indesign and flow the word document into it...
    I can able to flow the word document into the template using "Place" command..but script labels of the text frames gets disabled...
    I need the script labels to be enabled...
    can anybody help me
    thanks in advance

    Script labels can't be disabled, so I'm not sure what your problem is -- perhaps seeing some code could help. Could it be that you're referencing a page item by label, but it is not responding because the item is part of a group?
    Shane Stanley <[email protected]>
    AppleScript Pro Sessions <http://scriptingmatters.com/aspro>

  • Label in a text field

    Hi There
    I am struggling a little with putting a label into three text fields of a form - please see the site at http://www.justadwater.co.uk/Firstlook/index.html I can get it to appear when you click on the text box but it needs to be there from the start and then gone when you click on the box.
    Hope someone can help.
    Thanks
    G

    Hi,
    I believe this code should work.
    <form action="sendmailnews.php" method="post">
    <input name="First Name" id="Firstname" type="text" value="First Name"/>
    <input name="Last Name" id="Lastname" type="text" value="Last Name"/>
    <input name="Email" id="Email" type="text" value="Email"/>
    <input name="" type="image" id="button" src="images/button.gif"/></form>
    qazsd

  • Editing a label with unrecognized text

    Hi,
    I am trying to edit a label, and when I try and delete or add text with the touchup function, I get a message saying the selection contains text not available on the system(or something similar).  How do I remove and add text to this document?
    -Ken

    You probably get a better response in Adobe Acrobat forum, instead of Adobe Reader forum. Touch Up function is Adobe Acrobat feature
    I'm guessing you don't have the font installed. Does the message tell you what font you're missing? Or you can check Document Properties > Font tab and see what fonts are used in the PDF file, and get those fonts installed on your machine.
    Hope it helps!

  • Why TextFrames does not get exactly specified size?

    Hi, I'm experiencing the following problem:
    when I create some TextFrames and specify size using this code below:
    Illustrator.CharacterStyle curStyle = curDok.CharacterStyles.Add("ColorText" + text.Id.ToString());
    charAttr.Size = Convert.ToInt32(text.Size * 2.5F);
    charAttr.TextFont = newFont;
    curTextFrame.Contents ="SOME TEXT";
    curTextFrame.Top = 200;
    curTextFrame.Left = 200;
    curTextFrame.Height = 1000;
    curTextFrame.Width = 2000;
    curStyle.ApplyTo(curTextFrame.TextRange, false);
    I get different TextFrames size, when I save image into some file format(I've tried .eps and pdf). For example, if I specife 2000 width of th frame and create few frames with different text, they all get different sizes, some of them becomes 2300 width, etc. Is this some type of scaling, or what?
    P.S. If you have some code(in any language), that creates TextFrames, and they get exactly specified size, please, post it here. Thank you.

    If you don't need to be able to edit the text here is some code that should work. Worked for me using CS2 and Visual C# 2008.
    Illustrator.Application ai = new Illustrator.Application();
    Illustrator.Document doc = ai.Documents.Add(AiDocumentColorSpace.aiDocumentCMYKColor, 100, 100);
    Illustrator.CharacterStyle curStyle = doc.CharacterStyles.Add("ColorText");
    Illustrator.TextFont textFont = ai.TextFonts["Arial-Black"];
    int textSize = 20;
    curStyle.CharacterAttributes.Size = Convert.ToInt32(textSize);
    curStyle.CharacterAttributes.TextFont = textFont;
    Illustrator.TextFrame curTextFrame = doc.TextFrames.Add();
    curTextFrame.Contents = "SOME TEXT";
    curStyle.ApplyTo(curTextFrame.TextRange, false);
    Illustrator.GroupItem textGroup = curTextFrame.CreateOutline();
    textGroup.Top = 200;
    textGroup.Left = 200;
    textGroup.Height = 1000;
    textGroup.Width = 2000;
    Hope this helps.

  • How to get underline for a label?

    Hi All,
    I need to get underline for a label text.how to get this one?
    please help me to find out this?
    Regards,
    Lakshmi.

    Hi,
    There is no option line under line but if you want a uline under a label
    then there is other way of doing this.
    After label create a element with property horizontal gutter.
    This provides you a line under label.You can adjust the length of line using width .
    and you can adjust the heigth of line using heigth(small)etc according to your
    requirement.Also adjust ruletype by selecting from dropdown.

  • My phone has been smashed I need to get records of all my iMessages and texts from the last month. How do I get these?

    My phone has been smashed I need to get records of all my iMessages and texts from the last month. How do I get these?

    Do you have a backup of your iPhone which contains these messages?
    If so, you can restore a new iPhone from that backup during setup.
    If not, the messages are gone.

  • How to get the focus at the end of text ?

    I am having applet with awt TextField component and some default text. (MSQ-)
    To have a focus to text field I am using :
    refnoTextField.requestFocus();
    But this gives focus at the biginning and not at the end of text. I want the focus at the end (i.e. after MSQ-)
    How to get the focus at the end of text ?
    any help ?
    manisha
    manisha

    public void focusGained(FocusEvent e) {
         if (e.getSource() == yourtextbox) {
         yourtextbox.setSelectedEnd(yourtextbox.getLength());
    try this thing - not sure if it'll work, but I figgured out how to apply it to my textareas for keeping the focus on the last line of the textarea..it might work for your textboxes..
    shrug

  • Look at your iphoto 'page'. On the left is a margin running vertically down the page and within that margin are shown your files/folders - e.g 'events', I can't get that margin contents back

    Look at your iphoto 'page'.
    On the left is a margin running vertically down the page and within that margin are shown your files/folders - e.g 'events', 'last 12 months', 'anniversary' etc etc.
    Now visualize the 'page' but WITHOUT the margin and the entries in it. It just disappeared while I was editing photos.
    I've tried all the 'File', 'Edit', 'View', 'Share' 'Window' & 'Help' options, but no success.
    There is no apparent way of calling up onto the screen any photos, folders etc. because I can't get the margin and its contents back onto the iphoto page.
    I've tried restoring the page from my backup, where it is all perfect, but that didn't work.
    Help please!

    Move your cursor to the extreme left hand side of the iPhoto Window until it turns into a '+' and then click and drag right.

  • How to get rid of the black border around the artboard

    Hopefully my last question for tonight.
    I need to get rid of the black border around the artboard. The two images show my drawing lined up with the art board and then inside the artboard. The dark gray is not the artboard.
    As you see, the artboard has a black border. I need to get rid of it. It shows up in my project when my color key is green. The black won't go to transparent.
    So how-to get rid of the border? Thanks
    ***Update***
    I figured it out. View > Hide Artboards. Maybe this will help someone. Doesn't change the fact my spider looks like a tick:)

    Doesn't change the fact my spider looks like a tick:)
    Try to get hold of a real spider and take a look at its anatomy, specially where the legs sprout from :-)

Maybe you are looking for

  • My iPod touch still doesn't sync back Calender items - yours does?

    I asked this question before, and I still haven't solved the problem. Calendar items added in my iPod does not show up in my iCal after sync. I have choosen wich calendar to put it in, I have reset the Sync History in iSync, I have resetted my iPod a

  • 10.1.3.4 securing ADF application

    We have created 2 simple ADF based jsps. I want to secure them so that users are authenticated against our Ms Active Directory and based on their group membership they get access to 1 or both pages. I tried the examples under http://www.oracle.com/te

  • Scheduling dashboard or flash file

    Hello expert,          I want to design a WEBI report including multiple tables and a line chart. I want to implement this line chart in xcelsius , and combine it with WEBI in dashboard builder or I can directly develop this report wholly in XCELSIUS

  • 1120: Access of undefined property but4.

    stop(); import flash.events.MouseEvent; but3.enabled; but3.addEventListener(MouseEvent.CLICK, pla); but4.enabled; but4.addEventListener(MouseEvent.CLICK, sto); function pla(e:MouseEvent):void { gotoAndPlay(1); function sto(e:MouseEvent):void { stop()

  • How to generate the return code automatically through EP

    Hello all,            I have created a transaction Iview and i am calling transaction SE16 to which i am passing application parameter as the table name which i want to see.Now i am getting the SE16 screen with the table name successfully passed on t