How to change the length of the border?

On my picture, I want to be a top full border, no border bottom and two side borders that go only to half way down.

I know how to add the border, but I can't seem to be able to make the borders side down at halfway.

Is this possible?

Thank you! (:

A length of the border is to be determined by the element box or block encompassing level and in this case the width and height of the picture. Then no. However, you can use photoshop to add borders or add another div or any other element or a tag that is half the size of the photo and apply the border. Then position them accordingly.

Tags: Dreamweaver

Similar Questions

  • How to change the border style of the list items in the apex


    Hi all

    We have created a few items from the selection list in the Apex and ask users to make changes to the border.

    I tried many ways, but he was not able to make changes, some could help me how we can change the border style of list items in Apex. By, the approach has been used by us

    Attributes of the element in the HTML form -> style = "" border: 1px solid #E5E4E2; "" [I speak that way] but no luck.

    Kind regards

    Sheikh tayeb.

    SruthiTamiri wrote:

    Hello

    Please find the details below

    APEX version # 3.2

    Internet Explorer version #7

    Mozilla version 12.0.

    Used theme #Blue

    Topic identification number is #12

    It is not possible to change the appearance of the borders of the selection list in IE7.

    To the borders of all the elements of the selection list style on a page in other browsers, include the following style sheet in the HTML Header page:

    .formlayout select {
      border: 1px solid #E5E4E2;
    }
    

    APEX 3.2 is no longer supported, and IE7 is obsolete. Upgrade to the current version is recommended.

  • How to change the border against zero using javascript?

    Hello

    guys im quite new to adobe live cycle designer es2 I have a really easy.

    How can I change the hour or the appearance of a solid against zero TextBox after pressing a button

    I tried this on the FTT even click a button but seems to not work.

    NumericField1 [0] .border = 'None ';

    any suggestions? would be appreciated a youn noob.

    Hello

    The problem in your form was that it has been defined as static form.

    You must do the following to make the script work.

    (1) file menu Goto-> properties of the form and select the default values tab change the default rendering in dynamic XML form Format

    (2) select the Preview Tab. Set the type of overview as a form 'Interactive form' and preview Adobe XML dynamic XML form

    (3) Finally, while saving the PDF select Save As Type 'Adobe Dynamic XML Form.

    I corrected the form and is available at the link below.

    https://Acrobat.com/#d=R7qmed71zsu744V0Qvddvg

    Also try to give unique names to controls that are not related to each other.

    Thank you

    Srini

  • errorString - how to change the border thickness

    Hello! :)

    I want to do for the thicker inputText border when the errorString is set.
    Don't get what I need to do...
    This is my code:

    You can use setStyle in an event handler, preferably a ValidationResultEvent:
    textInput.setStyle ("borderStyle", "solid");
    CSS can not change this style.

  • change the border color of an image control

    Hi all

    I shows 30 photos on the façade by using an image control. I want the user to select 12 peaks of 30 photos.

    is there an interactive way to show what image has been selected. I thought that it would be OK to change the color of the border of the control.

    I would like to know how to change the border color of th and you are really welcome if you have a better way to say what peak has been selected.

    Thank you

    Ritesh

    Hi Ritesh,

    in my LV7.1 installation I could change bordercolor using the tool to color in development mode, but I couldn't find a property to change the colors by programming...

    So my advice would be to put a little bigger Boolean flags (or color boxes) behind the indicators of the photo. When the image is clicked/selected just change you the color of the underlying Boolean value. In this way imitate you the colorchanging of an indicator of the photo border...

  • How to change the property 'Border' of a Radio button?

    How to change the property 'Border' of a Radio button?

    TIA,

    -RFH

    What is the point of an option button if you can't see if it is checked or not?

    If you want a tool of indirect approach I suggest you use another thing. Maybe an annotation.

  • How to change the length of line objects

    Hi all

    How to change the length of the line objects.

    I know how to change the width or height of the elements.

    Utils < Facade::IGeometryFacade > ()--> (ResizeItems)
    itemList,
    Transform::PasteboardCoordinates (),
    Geometry::OuterStrokeBounds (),
    refPoint, Geometry::ResizeTo (newWidth, newHeight)
    );

    I know the new length and PMrect of the line item before moving.

    What I want to know is how to get the new width and height of this.

    Thank you.

    Fujimori - Satoru

    Find your old address of trigonometry and read the part about the Pythagorean theorem. This will give the scale factor you need to get the old PMRect to the new

  • How to change the style of picture frame

    I would like to know how to change the style of table on the front. For the example below, I would like to remove the covered framework of gray color.

    I could not find the table style editor.

    First option: use the table on the classic controls palette, which has no border.

    Second option-

    1. Select the painting tool.
    2. Right click on the border.
    3. With open color dialog box, click the space bar. This toggles the color picker to work on color FG, the background color, or both. It is also described at the bottom of the color picker.
    4. When the two have been selected, you can make the frame completely transparent by selecting the color of T.
  • How to change the input descriptor of return on investment?

    I am a beginner of Labview Vision users. I need to convert a RGB image into binary image and superimpose a few lines on the binary image at random and then measure the length of the ordinate at the origin of the image. I came across the problem of changing of return on investment by incorporating a few random coordinates (by this contact information, I can generate random lines.). But I could not find how to change the coordinates or import data from an excel file coordination.

    Any help is appreciated.

    Jian

    If you have the package of Vision, you can use the line to convert to the KING function and the power cable in the KING of the image property.  If you do not, you will need to build your own KING.  Given the coordinates of line (X 1, Y1) and (X 2, Y2) the entries in the return on investment are the following.

    Global rectangle - table of 4 elements with values [X 1, Y1, X 2 + 1, Y2 + 1]

    Countours - single element (table 4 external elements, line [X 1, Y1, X 2, Y2])

  • How to change the Spry CSS tab

    I like to use these old screens provided with the former DW Spry tab.  I just looked in DW CC and it looks like they aren't there and more.  But anyway, I made one for my client.  Now, they want to get one of the tabs on the far right of the margin.  See the image below:

    tabs.jpg

    I don't know yet if it's possible to do and if someone has done this before, can you tell me what code I need to change in the CSS?  I would have joined the CSS file, but it seems that you cannot attach files in this forum, so I've copied below.

    Please offer any means to change the color of the tabs, etc. - I just need to know how - or at all - this tab can be moved to the right.

    Thanks, Guy deaf

    PS I'm sorry that the CSS code does not correctly appear in this forum.  When I type this message, looks like it will display line-by-line, but it's not.  I'm sorry.

    ---------------------------------------------

    @charset "UTF-8";
    
    
    /* SpryTabbedPanels.css - version 0.6 - Spry Pre-Release 1.6.1 */
    
    
    /* Copyright (c) 2006. Adobe Systems Incorporated. All rights reserved. */
    
    
    /* Horizontal Tabbed Panels
     *
     * The default style for a TabbedPanels widget places all tab buttons
     * (left aligned) above the content panel.
     */
    
    
    /* This is the selector for the main TabbedPanels container. For our
     * default style, this container does not contribute anything visually,
     * but it is floated left to make sure that any floating or clearing done
     * with any of its child elements are contained completely within the
     * TabbedPanels container, to minimize any impact or undesireable
     * interaction with other floated elements on the page that may be used
     * for layout.
     *
     * If you want to constrain the width of the TabbedPanels widget, set a
     * width on the TabbedPanels container. By default, the TabbedPanels widget
     * expands horizontally to fill up available space.
     *
     * The name of the class ("TabbedPanels") used in this selector is not
     * necessary to make the widget function. You can use any class name you
     * want to style the TabbedPanels container.
     */
    .TabbedPanels {
      overflow: hidden;
      margin: 0px;
      padding: 0px;
      clear: none;
      width: 100%; /* IE Hack to force proper layout when preceded by a paragraph. (hasLayout Bug)*/
    }
    
    
    /* This is the selector for the TabGroup. The TabGroup container houses
     * all of the tab buttons for each tabbed panel in the widget. This container
     * does not contribute anything visually to the look of the widget for our
     * default style.
     *
     * The name of the class ("TabbedPanelsTabGroup") used in this selector is not
     * necessary to make the widget function. You can use any class name you
     * want to style the TabGroup container.
     */
    .TabbedPanelsTabGroup {
      margin: 0px;
      padding: 0px;
    }
    
    
    /* This is the selector for the TabbedPanelsTab. This container houses
     * the title for the panel. This is also the tab "button" that the user clicks
     * on to activate the corresponding content panel so that it appears on top
     * of the other tabbed panels contained in the widget.
     *
     * For our default style, each tab is positioned relatively 1 pixel down from
     * where it wold normally render. This allows each tab to overlap the content
     * panel that renders below it. Each tab is rendered with a 1 pixel bottom
     * border that has a color that matches the top border of the current content
     * panel. This gives the appearance that the tab is being drawn behind the
     * content panel.
     *
     * The name of the class ("TabbedPanelsTab") used in this selector is not
     * necessary to make the widget function. You can use any class name you want
     * to style this tab container.
     */
    .TabbedPanelsTab {
      position: relative;
      top: 1px;
      float: left;
      padding: 5px 20px;
      margin: 0px 1px 0px 0px;
      font: bold 12px sans-serif;
      background-color: #f1c185;
      list-style: none;
      border-left: solid 1px #CCC;
      border-bottom: solid 1px #999;
      border-top: solid 1px #999;
      border-right: solid 1px #999;
      border-radius: 5px 5px 0px 0px;
      -moz-user-select: none;
      -khtml-user-select: none;
      cursor: pointer;
    }
    
    
    /* This selector is an example of how to change the appearnce of a tab button
     * container as the mouse enters it. The class "TabbedPanelsTabHover" is
     * programatically added and removed from the tab element as the mouse enters
     * and exits the container.
     */
    .TabbedPanelsTabHover {
      background-color: #ffd197;
    }
    
    
    /* This selector is an example of how to change the appearance of a tab button
     * container after the user has clicked on it to activate a content panel.
     * The class "TabbedPanelsTabSelected" is programatically added and removed
     * from the tab element as the user clicks on the tab button containers in
     * the widget.
     *
     * As mentioned above, for our default style, tab buttons are positioned
     * 1 pixel down from where it would normally render. When the tab button is
     * selected, we change its bottom border to match the background color of the
     * content panel so that it looks like the tab is part of the content panel.
     */
    .TabbedPanelsTabSelected {
      background-color: #ffe9cd;
      border-bottom: 1px solid #EEE;
    }
    
    
    /* This selector is an example of how to make a link inside of a tab button
     * look like normal text. Users may want to use links inside of a tab button
     * so that when it gets focus, the text *inside* the tab button gets a focus
     * ring around it, instead of the focus ring around the entire tab.
     */
    .TabbedPanelsTab a {
      color: black;
      text-decoration: none;
    }
    
    
    /* This is the selector for the ContentGroup. The ContentGroup container houses
     * all of the content panels for each tabbed panel in the widget. For our
     * default style, this container provides the background color and borders that
     * surround the content.
     *
     * The name of the class ("TabbedPanelsContentGroup") used in this selector is
     * not necessary to make the widget function. You can use any class name you
     * want to style the ContentGroup container.
     */
    .TabbedPanelsContentGroup {
      clear: both;
      border-top: solid 1px #999;
      background-color: #FFF;
    }
    
    
    /* This is the selector for the Content panel. The Content panel holds the
     * content for a single tabbed panel. For our default style, this container
     * provides some padding, so that the content is not pushed up against the
     * widget borders.
     *
     * The name of the class ("TabbedPanelsContent") used in this selector is
     * not necessary to make the widget function. You can use any class name you
     * want to style the Content container.
     */
    .TabbedPanelsContent {
      overflow: hidden;
      padding: 4px;
    }
    
    
    /* This selector is an example of how to change the appearnce of the currently
     * active container panel. The class "TabbedPanelsContentVisible" is
     * programatically added and removed from the content element as the panel
     * is activated/deactivated.
     */
    .TabbedPanelsContentVisible {
    }
    
    
    /* Vertical Tabbed Panels
     *
     * The following rules override some of the default rules above so that the
     * TabbedPanels widget renders with its tab buttons along the left side of
     * the currently active content panel.
     *
     * With the rules defined below, the only change that will have to be made
     * to switch a horizontal tabbed panels widget to a vertical tabbed panels
     * widget, is to use the "VTabbedPanels" class on the top-level widget
     * container element, instead of "TabbedPanels".
     */
    
    
    .VTabbedPanels {
      overflow: hidden;
      zoom: 1;
    }
    
    
    /* This selector floats the TabGroup so that the tab buttons it contains
     * render to the left of the active content panel. A border is drawn around
     * the group container to make it look like a list container.
     */
    .VTabbedPanels .TabbedPanelsTabGroup {
      float: left;
      width: 10em;
      height: 20em;
      background-color: #EEE;
      position: relative;
      border-top: solid 1px #999;
      border-right: solid 1px #999;
      border-left: solid 1px #CCC;
      border-bottom: solid 1px #CCC;
    }
    
    
    /* This selector disables the float property that is placed on each tab button
     * by the default TabbedPanelsTab selector rule above. It also draws a bottom
     * border for the tab. The tab button will get its left and right border from
     * the TabGroup, and its top border from the TabGroup or tab button above it.
     */
    .VTabbedPanels .TabbedPanelsTab {
      float: none;
      margin: 0px;
      border-top: none;
      border-left: none;
      border-right: none;
    }
    
    
    /* This selector disables the float property that is placed on each tab button
     * by the default TabbedPanelsTab selector rule above. It also draws a bottom
     * border for the tab. The tab button will get its left and right border from
     * the TabGroup, and its top border from the TabGroup or tab button above it.
     */
    .VTabbedPanels .TabbedPanelsTabSelected {
      background-color: #EEE;
      border-bottom: solid 1px #999;
    }
    
    
    /* This selector floats the content panels for the widget so that they
     * render to the right of the tabbed buttons.
     */
    .VTabbedPanels .TabbedPanelsContentGroup {
      clear: none;
      float: left;
      padding: 0px;
      width: 30em;
      height: 20em;
    }
    
    
    /* Styles for Printing */
    @media print {
    .TabbedPanels {
      overflow: visible !important;
    }
    .TabbedPanelsContentGroup {
      display: block !important;
      overflow: visible !important;
      height: auto !important;
    }
    .TabbedPanelsContent {
      overflow: visible !important;
      display: block !important;
      clear:both !important;
    }
    .TabbedPanelsTab {
      overflow: visible !important;
      display: block !important;
      clear:both !important;
    }
    }
    

    !-[CodeBlockStart:dffe5525-a787-4a98-a87f-f24554b12141]-->@charset 'UTF-8'; / * SpryTabbedPanels.css - 0.6 - pre-release Spry 1.6.1 version * / / * Copyright (c) 2006] Adobe Systems Incorporated. All rights reserved. * / / * Horizontal tabbed panels * the default style for a TabbedPanels widget puts all the tab buttons * (stalled left) above the content panel. * / / * This is the selector for the main container of TabbedPanels. For our * style by default, this container does not contribute anything visually, * but it is floated to the left to ensure that all floating or compensation done * with any which of her children the elements lie entirely within the limits the * TabbedPanels container, in order to minimize any impact or unwanted * interaction with other floating elements on the page which may be used * for page layout. * If you want to limit the width of the widget TabbedPanels, define a * width of the container TabbedPanels. By default, the widget TabbedPanels * extends horizontally to fill the available space. * The name of the class ("TabbedPanels") used in this selector is not * necessary to make the widget service. You can use a class name, you * want to style the TabbedPanels container. */ . TabbedPanels {overflow: hidden;}   margin: 0px;   padding: 0px;   Clear: none;   Width: 100%; / * Hack IE to force the layout correct when preceded by a paragraph. (hasLayout bug) * /} / * this is the selector for the TabGroup. The container of TabGroup houses * all buttons on the tab for each tabs in the widget panel. This container * does not contribute to what both visually in the appearance of the widget for our * default style. * The name of the class ("TabbedPanelsTabGroup") used in this selector is not * necessary to make the widget service. You can use a class name, you * want to style the TabGroup container. */ . TabbedPanelsTabGroup {margin: 0px;}   padding: 0px; } / * This is the selector for the TabbedPanelsTab. This container houses * the title of the Panel. It is also tab 'button' that the user clicks on * to activate the corresponding content panel so that it appears on top * of the other tabs in the widget panels. * For our style by default, each tab is positioned relatively 1 pixel down from * where it would normally. This allows each tab overlap content * panel that renders underneath. Each tab is rendered with a background of 1 pixel * border which has a color that corresponds to the upper edge of the current content * panel. This gives the appearance that the tab is drawn behind the * content panel. * The name of the class ("TabbedPanelsTab") used in this selector is not * necessary to make the widget service. You can use any class name you want * to style the tab container. */ . TabbedPanelsTab {position: relative;}   Top: 1px;   float: left;   padding: 5px 20px;   margin: 0px 1px 0px 0px;   Police: bold 12px without serif.   background-color: #f1c185;   list-style: none;   border-left: 1px solid #CCC;   border-bottom: 1px solid #999;   border-top: 1px solid #999;   border-right: 1px solid #999;   border-radius: 5px 0px 5px 0px;   -moz-user-select: none;   -khtml-user-select: none;   cursor: pointer; } / * This selector is an example how to change the appearance of a button in the tab * container as the mouse enters in the it. The class is "TabbedPanelsTabHover" * programatically add and remove the element tab as the mouse between in * in and out of the container. */ . TabbedPanelsTabHover {background-color: #ffd197 ;} / * this selector is an example how to do to change the appearance of a button in the tab * container after the user has clicked on it to activate a content panel.} * The 'TabbedPanelsTabSelected' class is programmatically added and removed * the tab element as long as the user clicks button tab containers in * the widget. * As mentioned above, for our style by default, the tab buttons are positioned * 1 pixel down where he would normally. What is the tab key * selected, we change its bottom border to match the background color of the * content panel so that it looks like the tab is the content panel. */ . TabbedPanelsTabSelected {background-color: #ffe9cd;}   border-bottom: 1px solid #EEE; } / * This selector is an example of how to make a link inside a tab button * look like normal text. Users may want to use the links within a tab button * so that when it gets the focus, the text * inside * the tab button gets a focus * ring around it, instead of the ring around the whole tab. * /. TabbedPanelsTab a {color: black;}   text-decoration: none; } / * This is the selector for the ContentGroup. The ContentGroup container houses * all panels of content for each tabs in the widget panel. For our * style by default, this container provides the background color and borders that * surround content. * The name of the class ("TabbedPanelsContentGroup") used in this selector is * not necessary to make the widget function. You can use a class name, you * want to style the ContentGroup container. */ . TabbedPanelsContentGroup {clear: both;}   border-top: 1px solid #999;   background-color: #FFF; } / * This is the selector for the content panel. The content panel contains the * content for a single panel tabs. For our default style, this container * provides some padding, so that content is not pushed upward against the * widget borders. * The name of the class ("TabbedPanelsContent") used in this selector is * not necessary to make the widget function. You can use a class name, you * want to style the content container. */ . TabbedPanelsContent {overflow: hidden;}   padding: 4px; } / * This selector is an example of how to change the appearance of the currently * active panel container. The class is "TabbedPanelsContentVisible" * programatically added and removed from the content as the Panel item * is enabled/disabled. */ . TabbedPanelsContentVisible {} / * vertical tabbed panels * following rules override some of the default rules above so that the * TabbedPanels widget is rendered with its buttons on the tab on the left of * the active content panel. * With the rules defined below, the only change that will be made * to move a widget panels to horizontal tabs to vertical tabbed panels * widget, is to use the 'VTabbedPanels' class on the top-level widget * element container, instead of "TabbedPanels. */ . VTabbedPanels {overflow: hidden;}   Zoom: 1; } / * This selector floats the TabGroup so that the tab buttons it contains * make left of active content panel. A border is drawn around * the group container to make it look like a container from the list. */ . VTabbedPanels. TabbedPanelsTabGroup {float: left;}   Width: 10em;   height: 20em;   background-color: #EEE;   position: relative;   border-top: 1px solid #999;   border-right: 1px solid #999;   border-left: 1px solid #CCC;   border-bottom: 1px solid #CCC; } / * This selector disables the float property that is placed on each button of the tab * by the rule above TabbedPanelsTab default selector. He also draws a background * border for the tab. The tab button will get his left and right border of * the TabGroup and its superior border of the tab above it or button TabGroup. */ . VTabbedPanels. TabbedPanelsTab {float: none;}   margin: 0px;   border-top: none;   border-left: none;   border-right: none; } / * This selector disables the float property that is placed on each button of the tab * by the rule above TabbedPanelsTab default selector. He also draws a background * border for the tab. The tab button will get his left and right border of * the TabGroup and its superior border of the tab above it or button TabGroup. */ . VTabbedPanels. TabbedPanelsTabSelected {background-color: #EEE;}   border-bottom: 1px solid #999; } / * This selector fleet contained signs of the widget while they * make it to the right of the tabs buttons. */ . VTabbedPanels. TabbedPanelsContentGroup {clear: none;}   float: left;   padding: 0px;   Width: 30em;   height: 20em; } / * Printing styles * / @media print {.} TabbedPanels {overflow: visible! important;}. TabbedPanelsContentGroup {display: block! important;}   overflow: visible! important;   height: auto! important; } . TabbedPanelsContent {overflow: visible! important;}   display: block! important;   clear: both! important; } . TabbedPanelsTab {overflow: visible! important;}   display: block! important;   clear: both! important; } }

    Add the class like below:

  • Open Ocean
  • Delete the following in your css spry as file its in the ' query print media "and has no effect on the screen - have added you it to the wrong place."

    {.alignRight}

    position: relative;

    Top: 1px;

    float: right! important;

    padding: 5px 20px;

    margin: 0px 1px 0px 0px;

    Police: bold 12px without serif.

    background-color: #f1c185;

    list-style: none;

    border-left: 1px solid #CCC;

    border-bottom: 1px solid #999;

    border-top: 1px solid #999;

    border-right: 1px solid #999;

    border-radius: 5px 0px 5px 0px;

    -moz-user-select: none;

    -khtml-user-select: none;

    cursor: pointer;

    }

    Add the below css just above the press query written:

    {.alignRight}

    float: right! important;

    }

    / * Print styles * /.

    @media print {}

  • How to change the font of the title bar of the JFrame icon context menu?

    Hello world.

    I want to know how to change the font of the text that appears in the context menu is native to click with the right button on the icon that is completely left in the title bar of JFrames which use the default appearance for decoration (JFrame.setDefaultLookAndFeelDecorated (true); / / uses the metal L & F, theme "Océans").

    I searched and found nothing. I thought I could use what I learned to https://forums.oracle.com/message/9221826, but I couldn't find something that worked.

    Thanks to advance.t

    After a few more messing around, I finally did! I love so much it makes me a little sad Java how it is difficult to do things like that. In any case, I found a method here to recursively change the fonts of all components in a JFileChooser, but it does not work on the JPopupMenu (now I know the name) who jumps to the top of the icon in the title bar. So I messed around with this method a few casting and was able to change the fonts of the JMenuItems:

    public static void setSubComponentFont (Component comp[], Font font) {
        for (int x = 0; x < comp.length; x++) {
            if (comp[x] instanceof Container) {
                setSubComponentFont(((Container)comp[x]).getComponents(), font);
            }
            try {
                //comp[x].setFont(font);
                if (comp[x].toString().contains("JMenu")) {
                    for (Component y : ((JMenu)comp[x]).getPopupMenu().getComponents()) {
                        if (y.toString().contains("JMenu")) {
                            y.setFont(font);
                        }
                    }
                }
            } catch (Exception ex) {}
        }
    }
    

    I was inspired by this thread of utiliser.toString () .contains ().

    I also did with nested loops, so the path to the menu items can be seen:

    for (Component a : frame.getLayeredPane().getComponents()) {
        System.out.println(a.toString());
        if (a.toString().contains("MetalTitlePane")) {
            for (Component b : ((Container)a).getComponents()) {
                System.out.println(b.toString());
                if (b.toString().contains("SystemMenuBar")) {
                    for (Component c : ((Container)b).getComponents()) {
                        System.out.println(c.toString());
                        for (Component d : ((JMenu)c).getPopupMenu().getComponents()) {
                            System.out.println(d.toString());
                            if (d.toString().contains("JMenu")) {
                                d.setFont(font);
                            }
                        }
                    }
                }
            }
        }
    }
    

    Each System.out.println () gives an indication of what should go on what follows if State, so they should be used one at a time. This does not work for the title of the JFileChooser however font. When I have time I'll either look no further away inside or ask another question.

    So, if someone else needs like I did, it's here. As a tip, System.out.println () and. toString() are your friends! That's how I learned what was contained in each object, and which path I needed to take to get to objects of interest.

    Thanks anyway!

  • How to change the duration of a project on Adobe PR

    I'm not a big user of Prime Minister if can someone please explain how to change the duration of a project?

    The length of the sequence depends on the length of the added video.

  • How to change the angle of a gradient layer without changing anything else?

    How to change the angle of a gradient layer without changing anything else?

    When I try it myself my gradient everything turns black.

    To add to the above, you can just set the angle. If you want to use other existing parameters, you need to get from the layer. The code in this other thread shows a way to get them.

    But if you do not have the values for any other reason, you can get the handle to the layer, make a duplicate of it with all the settings and just crush those you want to change.

    It is a way to just change the angle while keeping the other existing settings.

    // helper function for working with descriptors
    function getProperty( psClass, psKey, index ){// integer:Class, integer:key
        var ref = new ActionReference();
        if( psKey != undefined ) ref.putProperty( charIDToTypeID( "Prpr" ), psKey );
        if(index != undefined ){
            ref.putIndex( psClass, index );
        }else{
            ref.putEnumerated( psClass , charIDToTypeID( "Ordn" ), charIDToTypeID( "Trgt" ) );
        }
        try{
            var desc = executeActionGet(ref);
        }catch(e){ return; }// return on error
        if(desc.count == 0) return;// return undefined if property doesn't exists
        var dataType = desc.getType(psKey);
        switch(dataType){// not all types supported - returns undefined if not supported
            case DescValueType.INTEGERTYPE:
                return desc.getInteger(psKey);
                break;
            case DescValueType.ALIASTYPE:
                return desc.getPath(psKey);
                break;
            case DescValueType.BOOLEANTYPE:
                return desc.getBoolean(psKey);
                break;
            case DescValueType.BOOLEANTYPE:
                return desc.getBoolean(psKey);
                break;
            case DescValueType.UNITDOUBLE:
                return desc.getUnitDoubleValue(psKey);
                break;
            case DescValueType.STRINGTYPE:
                return desc.getString(psKey);
                break;
            case  DescValueType.OBJECTTYPE:
                return desc.getObjectValue(psKey);
                break;
            case  DescValueType.LISTTYPE:
                return desc.getList(psKey);
                break;
            case  DescValueType.ENUMERATEDTYPE:
                return desc.getEnumerationValue(psKey);
                break;
        }
    };
    function duplicateDescriptor( descriptor ) {
        var newDescriptor = new ActionDescriptor;
        newDescriptor.fromStream( descriptor.toStream() );
        return newDescriptor;
    };
    function localizeDescriptor( desc ) {
        var stream, pointer, zStringLength, zstring, localized_string, newZStringLength, previousStream, followingStream, newDesc;
        stream = desc.toStream();
        while( true ) {
            pointer = stream.search(/TEXT....\x00\$\x00\$\x00\$/);
            if( pointer === -1 ) {
                break;
            }
            zStringLength = getLongFromStream( stream, pointer + 4 );
            zstring = readUnicode( stream.substr( pointer + 8, ( zStringLength - 1 ) * 2) );
            localized_string = ( localize( zstring ) ) + '\u0000';
            newZStringLength = localized_string.length;
            previousStream = stream.slice( 0, pointer);
            followingStream = stream.slice( pointer + 8 + zStringLength * 2);
            stream = previousStream.concat( 'TEXT', longToString( newZStringLength ), bytesToUnicode( localized_string ), followingStream );
        }
        newDesc = new ActionDescriptor();
        newDesc.fromStream( stream );
        return newDesc;
    };
    function getShortFromStream( stream, pointer ) {
        var hi, low;
        hi = stream.charCodeAt( pointer ) << 8 ;
        low = stream.charCodeAt( pointer + 1 );
        return hi + low;
     };
    function getLongFromStream( stream, pointer ) {
        var hi, low;
        hi = getShortFromStream( stream, pointer) << 16;
        low = getShortFromStream( stream, pointer + 2);
        return hi + low;
    };
    function readUnicode( unicode ) {
        var string = "";
        for( i = pointer = 0; pointer < unicode.length; i = pointer += 2) {
            string +=String.fromCharCode( getShortFromStream( unicode, pointer ) );
        }
        return string;
    };
    function longToString( longInteger ) {
        var string;
        string = String.fromCharCode( longInteger >>> 24 );
        string += String.fromCharCode( longInteger << 8 >>> 24 );
        string += String.fromCharCode( longInteger << 16 >>> 24 );
        string += String.fromCharCode( longInteger << 24 >>> 24 );
        return string;
    };
    function bytesToUnicode( bytes ) {
        var unicode = "", char_code, charIndex;
        for( charIndex  = 0; charIndex < bytes.length; charIndex ++ ) {
            char_code = bytes.charCodeAt( charIndex );
            unicode += String.fromCharCode(char_code >> 8 ) +  String.fromCharCode( char_code & 0xff );
        }
        return unicode;
    };
    
    function setGradientAdjustmentAngle( angle ) {
        var adjustmentDesc = getProperty( charIDToTypeID("Lyr "), charIDToTypeID( 'Adjs' ) ).getObjectValue(0);
        var newAdjustmentDesc = duplicateDescriptor( adjustmentDesc );
        newAdjustmentDesc.putUnitDouble( charIDToTypeID('Angl'), charIDToTypeID('#Ang'), angle );
    
        var desc = new ActionDescriptor();
            var ref = new ActionReference();
            ref.putEnumerated( stringIDToTypeID('contentLayer'), charIDToTypeID('Ordn'), charIDToTypeID('Trgt') );
        desc.putReference( charIDToTypeID('null'), ref );
        desc.putObject( charIDToTypeID('T   '), stringIDToTypeID('gradientLayer'), newAdjustmentDesc);
        executeAction( charIDToTypeID('setd'), desc, DialogModes.NO );
    };
    var newAngle = 45;
    setGradientAdjustmentAngle( newAngle );
    
  • How to change the color of the box

    Hello

    I want to change the color of the border of the checkbox (square shape). How can I do. I see control to change the color, but all are change fonts. I want to change the border/edge of the rectangular area that I check.

    Concerning

    Sunil

    It can be done as described here in the thread above.

    Here's a sample for you.

    https://workspaces.Acrobat.com/?d=YZazpiJgxQPoZEWtbvA-UQ

  • How to change the text design AS3 using the class Date

    Hi I tried to create a 24-hour countdown on 24 who will make a loop and play back counting it self down to 00:00:00:00

    Thanks to Andrei1 for providing me with this code to create the next animtion:

    var result: String = "";
    var date: Date = new Date (null, null, null, 0, 0, 0, 24);

    var timeDisplay:TextField = new TextField();
    timeDisplay.autoSize = TextFieldAutoSize.LEFT;
    timeDisplay.multiline = timeDisplay.wordWrap = false;
    timeDisplay.border = true;
    timeDisplay.x = timeDisplay.y = 20;
    timeDisplay.text = "00:00:00 ';

    addChild (timeDisplay);

    var: timer = new Timer (250);
    timer.addEventListener (TimerEvent.TIMER, count);
    Timer.Start ();

    function countDown(e:TimerEvent):void {}
    Date = new Date (date.setTime (date.getTime () - timer.delay));
    result = date.toTimeString () replace (/ \s+GMT\-\d + /, "");
    timeDisplay.text = result;
    }

    The end result, I'm looking for is to display this countdown clock in a clear gray arial font as shown in the picture below link:

    http://img801.imageshack.us/img801/3604/picture1ms.PNG

    Right now the code I received leaves me with a box around the type and a GMT (+ 000):

    http://img534.imageshack.us/img534/4264/picture2ot.PNG

    I was wandering if any body knows how to change the design of something in the photo above simular.

    Thank you for your help in advance.

    Tom

    Snippets of code is one thing, but nothing is gained back together solutions to people without explanation (but maybe a smile to not have to struggle with it).  Learning is not easy and it is better that it isn't... it involves the effort, stadiums, an increase in capacity to win.  You presented an entirely different approach to a solution that involves techniques beyond a beginning level.

    Don't you think that tom understands what he has in his hands?  It can develop its own regular expressions or manipulate a Date object to what you gave to him?  More importantly, since he never solved the intitial design of yesterdays issues poster, which has involved basic concepts much more, don't you think he could solve this design now?  Or he missed on some basic things that must precede the techniques that you have provided learning?

Maybe you are looking for

  • Cat invites so that on the phone?

    I'm relatively new to the iPhone. Today I was makin a phone call and was waiting when suddenly my phone began to vibrate furiously and (I'm working from memory here) a red and a green button appeared on the screen. They said something like Confirm an

  • setting priority-common output

    as stated I have 3 s vi that uses a common analog output. Vi2 & vi3 has first priority, a second vi1. VI1 waits until vi2 & 3 full using outputs analog. How can I achieve this? What would be the best solution? using queue or all the variables to set

  • computer laptop VAIO crashed lost operating system need to reformat the drive and delete partitions too

    I need a copy of windows xp because the manufacturer does not have a recovery disk and they no longer.so, what to do? I need to get a copy of xp that I have the license number on the bottom of my laptopMy laptop broke down with a virus and now I get

  • Words of end of line on print missing outs

    Original title: WF-2530 printer just bought this printer works fine except something allways printed at the end of the missing line entered in devices and printers clicked on properties but allways comes back on the material No matter how many times

  • iPhone 5 Code 43 Windows has stopped this device because it has reported problems

    Then, only in the past few days windows can't recognize my iPhone when I plug it via USB, and so does not charge or sync with iTunes. When I open the Device Manager, it says that the iPhone is an "unknown device" and displays the error code 43 (windo