3 Replies Latest reply on May 13, 2014 1:01 PM by jbante

    Is there any reason to create a style for an imported graphic?

    MHaskins

      In the Style Inspector there’s a “Graphic” section for imported images but there doesn’t currently seem to be any gain for creating styles for imported graphics. You can’t, that I know of, draw a “graphic” object on a layout and then apply a style to it, thus making an already-imported graphic appear (like you might do for a button object). So I have left my imported graphics all as “default” in the style inspector. Am I overlooking a reason for creating a style for each graphic?

        • 1. Re: Is there any reason to create a style for an imported graphic?
          mikebeargie

          Pictures can be styled like any other layout object. For example, I might want to add rounded corners to an image to make it a button, or add a gradient background to a transparent PNG I placed.

           

          If I save these to the default style for the "graphic" class of my theme, than any other images I place will automatically have the style applied, and any changes I make will be applied across my file.

           

          This is actually a fantastic feature, especially for those developers that regularly use images as buttons.

          • 2. Re: Is there any reason to create a style for an imported graphic?
            MHaskins

            Ah- yes! I see. Its not about saving the actual graphic, but the treatment of a graphic. Thx!

            • 3. Re: Is there any reason to create a style for an imported graphic?
              jbante

              Well, it can be about saving the actual graphic, too.

               

              Before FileMaker 13, many developers had a global repeating field in their applications that got loaded at startup. This way, developers could change the graphic throughout the file by swapping out the contents of one container field without making the change to every individual layout where that icon is used.

               

              Now that we have styles in FileMaker 13, I hope we see less of that. In 12, we gained the ability to use an image as the background fill for an object, such as a button. In 13, we can save that background fill as part of a style. By changing the background image used by a style throughout the file, we achieve the same effect without the schema overhead.