Skip to end of metadata
Go to start of metadata

Servoy uses a media library to manage all media items needed in a solution. Each solution has a Media node in Solution Explorer that is used to access the media items.

This chapter describes the supported media file types, how to import media into the library, how to view the media library, how to add media to a form, and how to manage media files.

In This Chapter

Supported Media

Virtually any type of media can be incorporated in Servoy. Servoy does have a built-in viewer for the following image file types:

  • GIF
  • JPG
  • JPEG
  • PNG

Users can import other file types, such as sound, video, and image files, into the media library.

Importing Media into the Library

There are several ways to import media files into a solution's Media library:

  • Drag and drop items from the OS file system into the Media node or the contextual list at the bottom of Solution Explorer.
  • Right-click to access the contextual menu on the Media node and select Import Media or Import Media Folder.
  • Use the mini-toolbar icons at the top of the Media contextual list in Solution Explorer.

Mini Toolbar key:

  1. View image
  2. Import media
  3. Import media folder
  4. Delete media
  5. Media Preferences

Viewing the Media Library

To view a solution's media library:

  1. Activate the solution (if not already active) by selecting it from the All Solutions node and choosing Activate from the contextual menu.
  2. Select the Media node. 
    • The full list of media items will be displayed in the contextual list at the bottom of the Solution Explorer.
    • By default, this list only includes media items in the solution's library.

To view items in modules assigned to the solution:

  1. Click on the Media Preferences button in the contextual list mini-toolbar.
  2. Select Include Entries from Modules. Media items inside modules will be added to the contextual list.

Adding Media to a Form

Media can be added to a form using either the Solution Explorer or the Form Editor Toolbar, which features a Place Media wizard with an image preview.

To add media using the Solution Explorer:

  1. Select the Media node to display the list of items in the contextual list.
  2. Select the desired item and drag it to the form.
  3. Drag the corners to resize the item as desired. (The inserted image is initially placed at its original size.)

To add media using the Form Editor toolbar :

  1. Click on the Place Media wizard button. !Screen shot 2011-06-14 at 10.11.12 AM.png|align=center!#* The Place Media wizard will open, showing the media items available in the solution (including items in modules' media libraries).
  2. Type a keyword in the filter field to limit the items displayed, if desired.
  3. Check the Preview box if you wish to preview the images, if desired (select an image to preview).
  4. Click OK to place the image.

Note: Media items need to be imported to solution's media library before using the Place Media wizard.

Tip: Media items can also be click-dragged to a Script Editor or CSS Editor window, in which case the file location for the media item will be inserted into the code.

Managing Items in the Media Library

Once placed in the Media library, items can be deleted, renamed, and moved or duplicated to another module's Media library. These functions are accessed via the context menu of each item when displayed in Solution Explorer.

Deleting an Item

To delete an item from the media library:

  1. Select the item in the contextual list.
  2. Click on the Delete icon in the mini-toolbar.

Alternatively, you can right-click on the item and select Delete from the context menu.

Renaming an Item

To rename a media item:

  1. Right-click on the item.
  2. Select Rename media item.
  3. Enter the new name in the window that opens.
  4. Click OK to confirm.

Moving an Item

To move a media item to another module in the currently active solution:

  1. Right-click on the item.
  2. Select Move media. A window will appear with a drop-down menu listing the modules in the solution that you can move the media item to.
  3. Select the desired destination from the drop-down menu.
  4. Click OK to confirm.

Duplicating an Item

A media item can be duplicated to another module in the currently active solution, or duplicated within the active solution's Media library. To duplicate an item:

  1. Right-click on the item.
  2. Select Duplicate Media. A new window will appear listing the available destinations and a text field for naming the duplicate item.
  3. Select the destination from the list.
  4. Type in a new name for the duplicate item.
  5. Click OK to confirm.
  • No labels