Class ExportMapAsImageAction<G extends GameObject<G,​A,​R>,​A extends MapArchObject<A>,​R extends Archetype<G,​A,​R>>

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean exportMap​(@NotNull MapControl<G,​A,​R> mapControl, boolean includeTiledMaps, @NotNull java.io.File file, @NotNull ExportMapProgress progress)
      Exports a map as an image file.
      void exportMapAsImage()
      Exports the current map as an image file.
      void setAction​(@NotNull javax.swing.Action action, @NotNull java.lang.String name)
      Sets the Action instance for this editor action.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ExportMapAsImageAction

        public ExportMapAsImageAction​(@NotNull
                                      @NotNull MapManager<G,​A,​R> mapManager,
                                      @NotNull
                                      @NotNull RendererFactory<G,​A,​R> rendererFactory,
                                      @NotNull
                                      @NotNull javax.swing.JFrame parent)
        Creates a new instance.
        Parameters:
        mapManager - the map manager instance for loading maps
        rendererFactory - the renderer factory for creating images from maps
        parent - the parent window for export map dialogs
    • Method Detail

      • exportMapAsImage

        @ActionMethod
        public void exportMapAsImage()
        Exports the current map as an image file.
      • setAction

        public void setAction​(@NotNull
                              @NotNull javax.swing.Action action,
                              @NotNull
                              @NotNull java.lang.String name)
        Description copied from interface: EditorAction
        Sets the Action instance for this editor action.
        Specified by:
        setAction in interface EditorAction
        Parameters:
        action - the action instance
        name - the name of the action
      • exportMap

        public boolean exportMap​(@NotNull
                                 @NotNull MapControl<G,​A,​R> mapControl,
                                 boolean includeTiledMaps,
                                 @NotNull
                                 @NotNull java.io.File file,
                                 @NotNull
                                 @NotNull ExportMapProgress progress)
        Exports a map as an image file.
        Parameters:
        mapControl - the map to export
        includeTiledMaps - whether to include tiled maps
        file - the output image file
        progress - the progress instance to notify
        Returns:
        whether exporting was successful