MBS FileMaker Plugin Example Databases

SVG to PNG

All examples are included with download of MBS FileMaker Plugin.

SVG to PNG.fmp12

Overview
Tables1
Relationships0
Layouts1
Scripts1
Value Lists0
Custom Functions0
Custom Menus0
File Options
Default custom menu set[Standard FileMaker Menus]
When opening file
Minimum allowed version12.0
Login usingAccount Name; Account= Admin
Allow user to save passwordOff
Require iOS passcodeOff
Switch to layoutOff
Hide all toolbarsOff
Script triggers
OnFirstWindowOpenOff
OnLastWindowCloseOff
OnWindowOpenOff
OnWindowCloseOff
OnFileAVPlayerChangeOff
Thumbnail Settings
Generate ThumbnailsOn; Temporary

 

Tables

Table Name
Statistics
Occurrences in Relationship Graph
SVG to PNG
5 fields defined, 1 record
SVG to PNG

Fields

Table Name: SVG to PNG - 5 Fields
Field NameTypeOptionsCommentsOn LayoutsIn RelationshipsIn ScriptsIn Value Lists
InputFileNormal, BinaryAuto-Enter:
  • Allow editing
Validation:
  • Only during data entry
Storage:
  • Repetitions: 1
      OutputFileNormal, BinaryAuto-Enter:
      • Allow editing
      Validation:
      • Only during data entry
      Storage:
      • Repetitions: 1
          Target Width in PixelNormal, NumberAuto-Enter:
          • Allow editing
          Validation:
          • Only during data entry
          Storage:
          • Repetitions: 1
          • Indexing: None
          • Automatically create indexes as needed
          • Index Language: German
              Target Height in PixelNormal, NumberAuto-Enter:
              • Allow editing
              Validation:
              • Only during data entry
              Storage:
              • Repetitions: 1
              • Indexing: None
              • Automatically create indexes as needed
              • Index Language: German
                  Resolution in DPINormal, NumberAuto-Enter:
                  • Allow editing
                  Validation:
                  • Only during data entry
                  Storage:
                  • Repetitions: 1
                  • Indexing: None
                  • Automatically create indexes as needed
                  • Index Language: German

                      Layout Objects: SVG to PNG

                      Regular Fields

                      Field Name: SVG to PNG::InputFile
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 59 pt
                      • Left: 73 pt
                      • Bottom: 472 pt
                      • Right: 501 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: Default for Data Type
                      • Go to next field using: Tab key
                      No

                      Field Name: SVG to PNG::OutputFile
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 59 pt
                      • Left: 576 pt
                      • Bottom: 472 pt
                      • Right: 1004 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: Default for Data Type
                      • Go to next field using: Tab key
                      No

                      Field Name: SVG to PNG::Target Width in Pixel
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 480 pt
                      • Left: 678 pt
                      • Bottom: 501 pt
                      • Right: 757 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: Default for Data Type
                      • Go to next field using: Tab key
                      Yes

                      Field Name: SVG to PNG::Target Height in Pixel
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 503 pt
                      • Left: 678 pt
                      • Bottom: 524 pt
                      • Right: 757 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: Default for Data Type
                      • Go to next field using: Tab key
                      Yes

                      Field Name: SVG to PNG::Resolution in DPI
                      Field PropertiesCoordinatesField FormatField BehaviorQuick Find
                      • Top: 526 pt
                      • Left: 678 pt
                      • Bottom: 547 pt
                      • Right: 757 pt
                      • Anchoring: Left, Top
                      Field Format:
                      • Edit Box
                      Field Behavior:
                      • Allow field to be entered: In Find mode, In Browse mode
                      • Touch keyboard type: Default for Data Type
                      • Go to next field using: Tab key
                      Yes

                      Buttons

                      Button PropertiesCoordinatesScript/Script Step
                        Type:
                      • Text: Convert
                      • Top: 480 pt
                      • Left: 885 pt
                      • Bottom: 511 pt
                      • Right: 1004 pt
                      • Anchoring: Left, Top
                      Perform Script [ “Convert” ]

                      Scripts:


                      Script Hierarchy

                      Convert

                      Script NameConvert
                      Run script with full access privilegesOff
                      Include In MenuYes
                      Layouts that use this script
                      Scripts that use this script
                        Script Definition
                        Script Steps
                        • #Load image from container
                        • Set Variable [ $image; Value:MBS( "GMImage.NewFromContainer"; SVG to PNG::InputFile ) ]
                        • Set Variable [ $name; Value:MBS( "Files.FileName"; GetAsText(SVG to PNG::InputFile) ) ]
                        • #Scale if parameters are filled in fields
                        • If [ IsEmpty ( SVG to PNG::Target Width in Pixel ) ]
                        • If [ IsEmpty ( SVG to PNG::Target Height in Pixel ) ]
                        • #both empty, do nothing
                        • Else
                        • Set Variable [ $r; Value:MBS( "GMImage.Scale"; $image; "99999x" & SVG to PNG::Target Height in Pixel & ">") ]
                        • End If
                        • Else
                        • If [ IsEmpty ( SVG to PNG::Target Height in Pixel ) ]
                        • Set Variable [ $r; Value:MBS( "GMImage.Scale"; $image; SVG to PNG::Target Width in Pixel& ">" ) ]
                        • Else
                        • Set Variable [ $r; Value:MBS( "GMImage.Scale"; // function $image; // pass in picture SVG to PNG::Target Width in Pixel & // width "x" & // by SVG to PNG::Target Height in Pixel & // height ">" // scale only if it will get smaller ) ]
                        • End If
                        • End If
                        • #If a resolution is defined, put it in
                        • If [ not IsEmpty ( SVG to PNG::Resolution in DPI ) ]
                        • Set Variable [ $r; Value:MBS( "GMImage.SetResolutionUnits"; $image; 1 /* pixel per inch */ ) ]
                        • Set Variable [ $r; Value:MBS( "GMImage.SetDensity"; $image; SVG to PNG::Resolution in DPI & "x" & SVG to PNG::Resolution in DPI) ]
                        • End If
                        • #Output to container
                        • Set Field [ SVG to PNG::OutputFile; MBS( "GMImage.WriteToPNGContainer"; $image; $name & ".png") ]
                        • #Cleanup
                        • Set Variable [ $r; Value:MBS("GMImage.Destroy"; $image) ]
                        Fields used in this script
                        Scripts used in this script
                          Layouts used in this script
                            Tables used in this script
                            Table occurrences used by this script
                            Custom Functions used by this script
                              Custom menu set used by this script

                                Download example: SVG to PNG

                                Used functions:




                                Links
                                MBS Xojo Plugins