Load or import custom style mapping in link options – is that possible somehow?

Hi Everyone,
I'm working with Instructions for Use and Technical Manual documents in InDesign. I'm constantly fine-tuning our templates, and now I have to refresh them again, because of a brand refresh. I'm using the Custom Style Mapping in the Link Options panel a lot, because it helps us to copy the text from older documents to the new ones with the right formatting, with less effort. The only thing I miss is the “Load/Import Custom Style Mapping” option from this panel.
Do you know if there’s any options to export/import/load these mappings somehow from one document to another? Is it possible to write a script for that? I find this part of InDesign quite unattached, it seems to me (based on my search) that no other people are using it. I feel lonely, help me here!
(I have created many new mappings in an older document, and I’d like to be able to use them in the new templates as well, but I can only do that if I map the styles again. And it’s quite time consuming. Maybe I'm just using too many paragraph styles, I have no idea – this could be another question: what is too much when it comes to styles...)
Thanks a lot,
Zita

Sync is not intended to be used as a backup service like you are talking about, but it will work as long as you save the Recovery Key, as Jefferson mentioned (you also need your Sync Username ''[email address you used]'' and your account Password).
Mozilla has just started working a new "cloud service" that is code named '''PiCL''' for "Profile in CLoud", which I am expecting will be a lot easier to use and might allow the user to access their bookmarks and other data from the internet without adding a "borrowed" PC to your Sync account.

Similar Messages

  • The custom style mapping option text still maintains the word formatting or it shows a style override in the InDesign style - how do I correct this?

    When I tell the custom style mapping option to format a Word style (from an rtf document) with the InDesign style, the text still maintains the word formatting or it shows a style override in the InDesign style. I have a large document that needs to import the styles correctly and I've followed the tutorials exactly however the placed text is still hanging onto the word RTF styles. I want the rtf text to convert to my InDesign styles completely without overrides.

    I actually need the cell styles. That's what sets my font, spacing, and GREP styles.
    I did find the solution today. In the table style or table setup, I needed to set the "Stroke Drawing Order" to "Column Strokes in Front". Even though it was previously set to "Best Joins" and I had no strokes for rows or for the table borders, it just wasn't giving priority to my dotted columns.
    Thanks for your response though!

  • Placing Word docs with custom style mapping

    I am trying to place Word 2007 docs in InDesign CS3 using custom style mapping.
    When I place the Word doc, InDesign creates a whole new set of styles with the correctly mapped new names but with the Word style definition. It records no name conflicts with the my already existing styles of the same names. Each of the new styles has the disc icon next to it, showing it was imported.
    If I delete each of the styles I can replace it with my original InDesign style, but isn't the point of style mapping to eliminate that step?
    Thanks.

    This issue is now solved in the 6.0.4 update. See the release notes for item #2335625.
    An important update to the InCopy and InDesign products has been released today!
    To install the update, choose Help > Updates from any Adobe CS4 application, or navigate to the Adobe Updater and launch it:
    Mac: /Applications/Utilities/Adobe Utilities/Updater6/Adobe Updater.app
    Win: C:\Program Files\Common Files\Adobe\Updater6\Adobe_Updater.exe
    You can also download the updates from Adobe.com at the following locations:
    InCopy Mac: http://www.adobe.com/support/downloads/product.jsp?product=30&platform=Macintosh
    InCopy Win: http://www.adobe.com/support/downloads/product.jsp?product=30&platform=WIndows
    InDesign Mac: http://www.adobe.com/support/downloads/product.jsp?product=31&platform=Macintosh
    InDesign Win: http://www.adobe.com/support/downloads/product.jsp?product=31&platform=WIndows
    Release notes are here: http://www.adobe.com/go/id6_readme_en

  • Importing Custom Style Sheets Into UiXML

    Is there any documentation on importing custom stylesheets (.css files) into UIXML. Has anyone one done this or know of a workaround if it cannot be done?
    Tks,
    Booker Northington II

    Hi Booker -
    Thanks for the clarification. Here is a sample which shows how to import a custom CSS style sheet into a UIX document using the HTMLWebBean:
    <?xml version="1.0" encoding="UTF-8"?>
    <page xmlns="http://xmlns.oracle.com/uix/controller"
    xmlns:ui="http://xmlns.oracle.com/uix/ui"
    xmlns:html="http://www.w3.org/TR/REC-html40">
    <content>
    <document xmlns="http://xmlns.oracle.com/uix/ui">
    <metaContainer>
    <head>
    <contents>
    <html:link rel="stylesheet" type="text/css" href="mystyles.css"/>
    </contents>
    </head>
    </metaContainer>
    <contents>
    <body>
    <contents>
    <styledText styleClass="myStyle" text="Hello, world!"/>
    </contents>
    </body>
    </contents>
    </document>
    </content>
    </page>
    Note: The <html:link> element inserts the HTMLWebBean which references the custom CSS file. We can then use styleClass="whatever" to reference the custom styles.
    Andy

  • HT5622 have 2 ipad and want to link them is that possible

    have just got new ipad and want all apps to go onto new ipad

    Transferring from old to new
    http://support.apple.com/kb/HT2109

  • XSLT Issue to open URL in new tab and PopUp Window through one custom style

    I have SharePoint Online Custom List that contains two columns
    Name: Single Line of Text
    URL: Hyperlink or pictures
    Using XSLT I have shown Name columns value on my home page by using below custom style in
    Itemstyle.xsl file.
    Custom style to show Link in PopUp window   itemstyle.xsl
    <xsl:template name="OpenApplicationPagePopUp" match="Row[@Style='OpenApplicationPagePopUp']" mode="itemstyle">
    <xsl:variable name="SafeLinkUrl">
    <xsl:call-template name="OuterTemplate.GetSafeLink">
    <xsl:with-param name="UrlColumnName" select="'LinkUrl'"/>
    </xsl:call-template>
    </xsl:variable>
    <xsl:variable name="DisplayTitle">
    <xsl:call-template name="OuterTemplate.GetTitle">
    <xsl:with-param name="Title" select="@Title"/>
    <xsl:with-param name="UrlColumnName" select="'LinkUrl'"/>
    </xsl:call-template>
    </xsl:variable>
    <div class="item link-item">
    <xsl:call-template name="OuterTemplate.CallPresenceStatusIconTemplate"/>
    <a href="{$SafeLinkUrl}" onclick="ShowPopupDialog(GetGotoLinkUrl(this));return false;">
    <xsl:if test="$ItemsHaveStreams = 'True'">
    <xsl:attribute name="onclick">
    <xsl:value-of select="@OnClickForWebRendering"/>
    </xsl:attribute>
    </xsl:if>
    <xsl:if test="$ItemsHaveStreams != 'True' and @OpenInNewWindow = 'True'">
    <xsl:attribute name="onclick">
    <xsl:value-of disable-output-escaping="yes" select="$OnClickTargetAttribute"/>
    </xsl:attribute>
    </xsl:if>     
    <xsl:value-of select="$DisplayTitle"/>
    </a>
    </div>
    </xsl:template>
    My Requirement to show only Suggestion Box in Popup window Other Links Should be open in new Tab So please suggest me what can change in above xslt...
    Thanks
    Deepak Chauhan
    SharePoint 2010 & 2013 and Office-365 Branding and Front End Customization, UI Design

    Hi,
    In SharePoint 2013, we can use JSLink to achieve it.
    1. Save the following code as a js file (URLPopup.js) and upload it into the
    SiteAssets Document Library.
    // List View – Field open modal dialog Sample
    (function () {
    // Create object that have the context information about the field that we want to change it output render
    var linkFiledContext = {};
    linkFiledContext.Templates = {};
    linkFiledContext.Templates.Fields = {
    //Apply the new rendering for URL field on List View
    // "URL" is the column name.
    "URL": { "View": URLFiledTemplate }
    SPClientTemplates.TemplateManager.RegisterTemplateOverrides(linkFiledContext);
    // This function provides the rendering logic for list view
    function URLFiledTemplate(ctx) {
    var itemTitle=ctx.CurrentItem.Title;
    var urlLink=ctx.CurrentItem.URL;
    var urlDesc=ctx.CurrentItem['URL.desc'];
    if(urlLink!=null&&urlLink!=""){
    if(itemTitle=="Suggestion Box"){
    return "<a href='#' onclick=\"openModalDialog('"+urlLink+"')\">"+urlDesc+"</a>";
    }else{
    return "<a href='"+urlLink+"' target='_blank'>"+urlDesc+"</a>";
    }else{
    return "";
    function openModalDialog(url)
    var options = {
    title: "Suggestion Box",
    autoSize: true,
    url: url
    SP.UI.ModalDialog.showModalDialog(options);
    return false;
    2.Edit the list view page.
    3.Edit the list web part. Go to Miscellaneous -> JS Link.
    4.Add the following URL into the JS Link textbox.
     ~site/SiteAssets/URLPopup.js
    5.Click "OK" and save the page.
    Best Regards
    Dennis Guo
    TechNet Community Support

  • Export Custom Attribute Mapping

    Hello Gurus!
    I'm migrating a xMII 11.5 project to MII 12.1 and the migration tool was fine on creating the Custom Attributes and Custom Attribute Mapping. However, what I need now is to export Custom Attribute and Custom Attribute Mapping from MII 12.1 DEV to QAS and PRD.
    My question is: When exporting Custom Attributes from Configurations menu, it will export Custom Attribute Mapping too? How can I export and import Custom Attribute Mapping from DEV to QAS and PRD?
    Thanks

    Manoel,
    have you tried the following:
    - open System Management / Configurations
    - unmark the "Select All" and only mark the "Custom Attributes"
    - click export and save the zip file
    The exported zip file should include all the settings. In your follow up systems QAS and PRD you can import the zip file.
    See also SAP Help on [MII 12.1 Configuration|http://help.sap.com/saphelp_mii121/helpdata/en/43/e80b59ad40719ae10000000a1553f6/frameset.htm]
    Michael

  • Can a DTD map custom styles to standard HTML tags?

    Hi,
    Every week the publishing house I work for has to manually copy the entire content of a weekly magazine on an article-by-article basis into an online database, the web version of the magazine. This means copying the styled InDesign content and inserting it into the database as plain text, re-finding all those italics (and any other styling) and putting it all back manually.
    I already know that I can create tags with all the basic HTML styles needed in the 'Tags' palette in InDesign, and then export that.
    The trouble is that when I re-import the XML file, I have to laboriously map the custom house-styles (there are many of them and they're boiler-plate, i.e. consistent, across all the magazine's InDesign styles) to the imported HTML styles.
    So here's my question:
    Am I wrong to believe that it's possible to create a DTD that would import not only the HTML tags but their relationship to the existing, custom-named InDesign tags that are common to all the magazine's documents?
    As an InDesign wish-feature, what's missing from the 'Tags' corner-menu is 'Export DTD' - if that was available, I could map the whole relationship between Indesign Styles/HTML styles just one time and later import the DTD on other articles; which would tell the Structure View how to convert our custom house-styles (both Paragraph Styles and Character Styles) into HTML tags and cut this time-consuming task in half.
    Thanks!
    EDIT: I perhaps should have mentioned that obviously the final stage after this 'dream conversion' is to export the XML from the Structure View. Then I can just open the saved XML file and paste it into the CMS with formatting intact.
    Added extra explanation of the workflow.

    geekbelief wrote:
    Googling XSLT and InDesign, it seems that such a stylesheet, if I were to create it, possibly couldn't handle spaces in the original InDesign style-names..? If anyone knows that for a fact, I'd be glad to be aware of it before starting down a long path to a roadblock.
    That's a good question. Let's find out together, shall we. I just created a text frame with Lorem Ipsum text, and created "a style" (with space) and "bstyle" (without). Now ... Map Style to Tag doesn't work, presumably because the tags don't exist and I assumed this would *create* them. And if you create one, ID complains "tags cannot contain tabs or spaces". (So can you have a Tab in your paragraph style name then? Gosh.)
    ... Forcing in a Non-breaking Space (#160) also doesn't work, this time ID simply says "A tag name cannot contain the character ' '."
    I think that's one you have to do manually.
    geekbelief wrote:
    I'm guessing that if I wanted to change the InDesign style 'Subheader' into 'h2', that snippet of the XSLT would be like this...?
    <xsl:template match="Subheader"><h2><xsl:apply-templates /></h2></xsl:template>
    Yeah, that's the correct syntax. But you cannot use an XSLT for mapping InDesign styles to tags. The process as I described works when importing your XML into InDesign, and changes the tags in the XML file to match InDesign styles. That's the other way around.
    I don't expect anyone to write this for me, but any hints or links to tutes that I haven't yet found would be appreciated!
    For a simple one-to-one translation of tag names, you can use this all the way. You only need any other XSL command if you want to do more than simple translation, such as filtering, moving, combining, or separating tags or their contents.
    There are lots of good tutes on the 'web for XSLT, although it seems interest has diminished lately. Half a decade ago XSLT was "hot"; nowadays the iPad is. Is there any news on improvements for ID's native XSLT support in CS6? I dare bet there are none at all -- it's already been deemed "yesterday's technology" by Adobe's Dev Team, just as Flash was discarded per CS5.5. I'm sure next year DPS will follow; and the year after that EPubs will be gone for good as well, replaced by holograms, transmitted live from your local library.

  • Is Custom Style Sheet Working?

    I'm trying to use a custom style sheet, in order to block ads, but I don't think it works in this version of Safari. (on OS X 10.4, I use a custom CSS file and it works great.) In the Windows beta, it does nothing.
    I even tried a simple custom style sheet to hide all images:
    img { display: none ! important }
    and set that, but all image still display.
    So, is it broken??

    Cool! That does work.
    Except...
    I had downloaded the nightly Webkit build for Windows (nightly.webkit.org) - which btw has the nifty "inspect Element" menu item enabled!
    But - that doesn't like the custom style sheet - Safari would crash every time I tried to load a page that had some element that would have been blocked. I even tested it with a simple custom stylesheet that just has:
    img { display: none ! important };
    At least I don't have to wait long to try it with a new Nightly build!

  • Custom style in websheets

    Starting with APEX 4.1 we could use a custom style for web sheets by providing our own CSS commands.
    Did anybody experiment with that? Which classes / IDs should we use?
    Or might there even be documentation about that? In the official APEX documentation I could only find this sentence ;): "Use the Style section to override default application style and use a custom CSS."
    Regards,
    ~Dietmar.

    Hi Sam,
    I don't use the web toolkit myself, but the principles of css should still apply. That is, if you have two, or more, css style rules for an object (referenced either by tag type, id or class name etc), the last style found for each style setting is used. For example, if you have two styles for a class called "xxx" and both contain a border definition, the second definition will be applied.
    You can control this in two ways:
    1 - Make sure that the STYLE tag for the styling to want to take effect is loaded after the Theme 20 stylesheet. You could probably do this in the page's HTML Header setting
    2 - Add *!important* after any style that you want to take precendence over any subsequent style. For example, suppose your first style tag contains:
    .xxx {border:1px solid blue}and your custom style contains:
    .xxx {border:1px solid red}You will get a red border unless you change the first one to:
    .xxx {border:1px solid blue!important}when you will get a blue border
    Andy

  • Import RPC-style WSDL

    Hello!
    I currently implement a RFC -> RFC adapter -> XI -> SOAP adapter -> Web Service scenario. I have imported the WSDL of the Web Service as External Definition into the Integration Repository to use it for the RFC <-> Web Service mapping within the graphical mapping tool.
    Until now I only have imported document-style WSDL and there never have been any problems. Now the WSDL is RPC-style which means that the messages described by the <wsdl:types>...</wsdl:types> part should be enclosed by an additonal structure describing the Web Service operation to be executed.
    However, in the graphical mapping tool the structure for  the Web Service operation is missing and thus the Web Service call cannot be executed. How can I solve this problem without changing the WSDL or creating an additional XLST or Java mapping?
    It seems that there is no problem with the WSDL. When I loaded it with the Web Service Navigator test tool of the SAP Web Application Server the structure describing the Web Service operation has been generated in the request message.
    Regards, Tanja Schättler

    Hi Tanja
    Check this note 856597, it even has some examples of WSDL documents and sample SOAP messages that illustrate how one can write an equivalent WSDL in another style.
    A snippet from the note,
    "Q: Can I convert an RPC styled WSDL to a document styled WSDL?
                A: It is difficult to answer yes or no because the answer depends on the WSDL instance and the implementation of the code that binds the XML instance to some native object. The problem comes from the fact that these two styles describe web services in different layers. The document style WSDL describes how one can bind an XML document to the SOAP message format. In contrast, the RPC style WSDL describes how one can bind an object to the SOAP message format. One can imagine that this works in two steps: first representing the object as an XML document and then binding this XML document to the SOAP message format. How this first step works is controlled by the SOAP encoding name. For the standard encoding specified in the SOAP specification, most objects can be easily described in an equivalent XML schema. Some special objects such as references and arrays must be represented by some special rules and some additional meta information in XML. This implies that these additional attributes and elements must also be described in the XML schema and the document style based proxy must set these values in the instance appropriately.
                One must however note that even if one has an equivalent document style WSDL, this does not automatically guarantees the interoperability. Some RPC styled service implementations have significant interoperability problems such as requiring the xsi:type attribute for every element or the SOAP encoding attribute at some particular element. If one has to call such non conformant SOAP service, one must adjust the message accordingly.
               Attachment wsdl_style_samples. zip contains some examples of WSDL documents and sample SOAP messages that illustrate how one can write an equivalent WSDL in another style.
                Related Questions "Does the RPC or Document style in WSDL play a role in the SOAP adapter?"
    cheers
    Sameer

  • Error while deploying, Custom Style Skin in OBIEE 11.1.1.6.7

    Hi,
    I have deployed Custom Style Skin in OBIEE 11.1.1.5 successfuly (with the help of http://www.rittmanmead.com/2010/12/oracle-bi-ee-11g-styles-skins-custom-xml-messages/ ).
    Now when we're moving RPD, Catalog & Custom Style Skin from OBIEE 11.1.1.5 to OBIEE 11.1.1.6.7, I could deploy RPD & Catalog but am not able to deploy Custom Style & Skin Folders.
    If you are aware of the process of deploying Custom Style & Skins (as mentioned in the link above), it requies:
    1. Custom Style & Skins folder to be Deploy using Weblogic Console.
    2. Making necessary changes in instanceconfig.xml (to point to the deployed folder) ---- this is where it's failing.
    When I do add necessary tags ( <URL> & <UI>) in instanceconfig.xml and restart Services. Presentation Services dosen't come up. Error message that is in log file is:
    In element URL: Can not have element children within a simple content.
    unknown element 'UI'
    Element 'UI' is not valid for content model : 'All(URL, SocketTimeoutSec,FileSizeMB)'
    Any pointers?
    Regards,
    Jitendra

    Hi,
    I too faced such issue, actually obiee11.1.1.5 version skin and style wont work in obiee11.1.1.6.0 and above patch ..
    u have do it once again by using obiee11.1.1.6.0 skin (because the 11.1.16.0 has UI and skin different from 11.1.1.5.0 )
    Thanks
    Deva

  • SharePoint 2013 RTE Custom Styles lost on Team Site Wiki Page after you select a control in the editor

    I have a weird issue in that I have custom RTE styles working fine in publishing pages, but in the team site wiki page, when you first go into edit mode you see your styles, but if you highlight some text, select say the font drop down to expand it and then
    select it again to contract it (i.e. without selecting a font), all of a sudden all of the custom styles are lost and everything reverts back to the default RTE styles.
    In my master page I am running the following script to force my styles to be loaded.
    ExecuteOrDelayUntilScriptLoaded(
    function() {
         $(
    "div[RteRedirect]").each(function()
    varid = $(this).attr("RteRedirect"),
             editSettings = $(
    "#"+ id);
    if(editSettings.length > 0 &&
    editSettings[0].PrefixStyleSheet != 'custom-rte')
                 editSettings[0][
    'PrefixStyleSheet'] =
    'custom-rte';
                 editSettings[0][
    'StyleSheet'] =
    '\u002f_layouts\u002f15\u002fFiveP\u002frteStyles.css';
                 RTE.Canvas.fixRegion(id,
    false);
    "sp.ribbon.js");
    See below screenshots (note Heading 2 is orange).
    After you collapse the font menu, you see that the orange H2 has disappeared, and selecting the font drop down again now shows all of the default SharePoint RTE styles.
    I haven't been able to capture the Event that is being called using the debugger. Any ideas how to fix this?
    Alan Coulter.

    Hi,
    For this issue, I'm trying to involve someone familiar with this topic to further look at it.
    Thanks,
    Qiao
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Qiao Wei
    TechNet Community Support

  • How can I make a custom style look the same in both printed and online?

    My specs:
    RH 9.0.2.271
    Windows 7, 64-bit
    Word 2010
    The Background Info:
    So I created some custom css styles to try and mimic the look of a message box in our documentation. Here's the css code:
    .MsgBox {
        color: #000000;
        border-left-style: Solid;
        border-right-style: Solid;
        border-top-style: Solid;
        border-bottom-style: Solid;
        font-size: 10pt;
        background-color: #eeeeee;
        border-left-width: 4px;
        border-right-width: 4px;
        border-top-width: 4px;
        border-bottom-width: 4px;
        border-left-color: #cdcdcd;
        border-right-color: #cdcdcd;
        border-top-color: #cdcdcd;
        border-bottom-color: #cdcdcd;
        width: 350px;
        padding: 5px 5px 5px 5px;
        box-shadow: 10px 10px 5px #888888;
        margin-bottom: 7pt;
    .MsgBoxTitle {
        color: #000000;
        border-left-style: Solid;
        border-right-style: Solid;
        border-top-style: Solid;
        border-bottom-style: Solid;
        font-size: 10pt;
        background-color: #cdcdcd;
        border-left-width: 4px;
        border-right-width: 4px;
        border-top-width: 4px;
        border-bottom-width: 0px;
        border-top-color: #cdcdcd;
        border-bottom-color: #cdcdcd;
        border-left-color: #cdcdcd;
        border-right-color: #cdcdcd;
        width: 350px;
        padding: 5px 5px 5px 5px;
        box-shadow: 10px 10px 5px #888888;
    My HTML Code:
    <div class="MsgBoxTitle">
        PC-DMIS MESSAGE:
    </div>
    <div class="MsgBox">
        <p>Please do the following steps in the indicated order.</p>
        <p>1. Remove the current SH-1/2/3 stylus.</p>
        <p>2. Attach the SHSP (Stylus Holder Setting Piece).</p>
        <p>3. Jog the probe to a safe location with a clear line of approach
         to the port(s) being calibrated. </p>
        <p>4. Then click OK.</p>
        <p>After you click OK the machine will begin DCC measurement.</p>
    </div>
    The Expected Output:
    Here's how it renders in a browser (the title is MsgBoxTitle, the body is the MsgBox style). I'm happy with how it looks there, even if the box shadow doesn't always display:
    The Ugly Printed Output:
    And here's what it looks like in the printed output.
    Ugly. Are there any tricks to get the printable (doc) output to match the online? Ideally, on the printed output, I'd like to have all the white space in my pseudo message box removed so it looks just like the online.

    Hi Peter. Thanks for the reply.
    I assumed that if I used the project style sheet during the export, Word would convert the style so that it looked the same as in the HTML. Is that a bad assumption? I'm currently not mapping to any template equivalent for these message box styles. I did try it as one of my attempts, but I couldn't figure it out. It never seemed to take the style in the .dot.
    Anyway, if I use just 1 style, such as just the MsgBox, I obviously don't get the white paragraph between the title and message. That white paragraph comes from the first <p> tag in the MsgBox style. But I need to have the <p> tags in there because they're better for our localization process than line breaks.
    I did do some tweaks that made it look better. Basically I structured it so that the MsgBoxTitle div is now inside the MsgBox div. Something like this:
    <div class="MsgBox">
        <div class="MsgBoxTitle">PC-DMIS MESSAGE: </div>
        <p>Please do the following steps in the indicated order.</p>
        <p>1. Remove the current SH-1/2/3 stylus.</p>
        <p>2. Attach the SHSP (Stylus Holder Setting Piece).</p>
        <p>3. Jog the probe to a safe location with a clear line of approach
         to the port(s) being calibrated.</p>
        <p>4. Then click OK.</p>
        <p>After you click OK the machine will begin DCC measurement.</p>
    </div>
    And then I adjusted my styles borders, padding, and thickness. That helped it look more connected, but still doesn't look quite right:
    Would love to get rid of that white space after the title.
    If you have time, I would be interested in a more detailed example of how you did it.

  • How do I add custom style to custom AS3 component via .css file?

    Hi all,
    I have created a flex application which displays a custom component I created in actionscript. My custom component is just an extended canvas component which displays a gradient background. When I add the component to my flex app, see code below, the component works great.
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" xmlns:ns1="http://localhost/mycomps">
        <ns1:GradientCanvas fillColors="[#ffffff, #000000]" />
    </mx:Application>
    However, I also want to support css styles to add the gradient colors to my component, like so
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" xmlns:ns1="http://localhost/mycomps">
        <mx:Style source="test.css" />
        <ns1:GradientCanvas styleName="gradientCanvas" />
    </mx:Application>
    test.css
    .gradientCanvas {
        fill-colors: #ffffff, #000000;
    When I try this my component doesn't display a gradient. I have followed the tutorials online that I could find but it seems to be the same example from Adobe repeated on multiple site and it doesn't work.
    My component code is added below, if anyone could show me how to get this to work it would be much appreciated.
    Thanks in advance,
    Xander
    GradientCanvas.as
    package mycomps {
        import flash.display.GradientType;
        import flash.geom.Matrix;
        import mx.containers.Canvas;
        import mx.styles.CSSStyleDeclaration;
        import mx.styles.StyleManager;
        public class GradientCanvas extends Canvas {
            private static var classConstructed:Boolean = constructStyle();
            public function GradientCanvas() {
                super();
                this.width = 100;
                this.height = 20;
            private static function constructStyle():Boolean {
                var style:CSSStyleDeclaration = StyleManager.getStyleDeclaration("GradientCanvas");
                if (style) {
                    if (style.getStyle("fill-colors") == undefined) {
                        style.setStyle("fill-colors", [0xffffff, 0x000000]);
                } else {
                    style = new CSSStyleDeclaration();
                    style.defaultFactory = function():void {
                        this._fillColours = [0xffffff, 0x000000];
                    StyleManager.setStyleDeclaration("GradientCanvas", style, true);
                return true;
            override public function styleChanged(styleProp:String):void {
                super.styleChanged(styleProp);
                if (styleProp == "fill-colors") {
                    this._fillColours = getStyle("fill-colors");
                    this._fillColoursChanged = true;
                    this.invalidateDisplayList();
            override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void {
                super.updateDisplayList(unscaledWidth, unscaledHeight);
                if (this._fillColoursChanged == true) {
                    var direction:Number = 90 * (Math.PI / 180);
                    var matrix:Matrix = new Matrix();
                    matrix.createGradientBox(unscaledWidth, unscaledHeight, direction, 0, 0);
                    graphics.clear();
                    graphics.beginGradientFill(GradientType.LINEAR, this._fillColours, [1,1], [0, 255], matrix, "pad", "rgb", -1);
                    graphics.drawRect(0, 0, unscaledWidth, unscaledHeight);
                    graphics.endFill();
                    this._fillColoursChanged = false;
            [Inspectable(category="Gradient", type="Array", format="Color", name="Fill Colours")]
            private var _fillColours:Array;
            private var _fillColoursChanged:Boolean = false;
            public function get fillColours():Array {
                return this._fillColours;
            public function set fillColours(value:Array):void {
                this._fillColours = value;
                this._fillColoursChanged = true;
                this.invalidateProperties();
                this.invalidateDisplayList();

    Never mind, I've discovered how to do it for myself.
    Thanks...

Maybe you are looking for

  • [CS3] [JS] Export PDF to the same folder as the InDesign file

    Hi, I have written a JavaScript to export an InDesign file to a PDF file. The exporting works fine when exporting to a specific folder, but I want the script to export the PDF to the SAME folder as the InDesign file. For example, if the Indesign file

  • Limiting stepper results

    First, thanks again for the help with my checkbox problem. This question is similar in nature. In cell A1 I have a slider box with a range of 3 to 10. I have two stepper (or slider) boxes in cells B1 and C1, that each have a range from 0 to 10. I wou

  • Needed to reinstall parts of Gnome after hardware problem?

    Wasn't sure exactly where to post this, but I suppose this is the best place for it. Thankfully, I've already solved my problem but I wonder if anyone has any ideas on why it was a problem in the first place. Apparently, either my CPU or my motherboa

  • Are there any security issues with Quicktime player on macbook

    Are there any security issues with Quick Time Player on macbook pro? 2010 model running Yosemite recently upgraded. Thanks!

  • Lost all Messages after restoring backup on x2-01

    i have a nokia x2-01 and i have backed up all my messages to a memory card... then i restored that backup.. and after restore there are no messages in my messages folder.... is there any way to restore all my messages??