Wallpaper

Returns or sets the wallpaper bitmap of the specified view. To remove a wallpaper bitmap, pass an empty string, or "", as the filename to display.

Syntax

rhinoscriptsyntax.Wallpaper(view=None, filename=None)

rhinoscript.view.Wallpaper(view=None, filename=None)

Parameters

view

Optional.  String or Guid.  The title or identifier of the view.  If omitted, the current active view is used.

filename

Optional.  String.  The name of the bitmap file to set as the wallpaper.  The supported bitmap file formats are as follows:

.bmp

Windows Bitmap

.tga

Truevision Targa

.jpg, .jpeg

JPEG Compliant

.pcx

Zsoft Paintbrush

.png

Portable Network Graphics

.tif, .tiff

Tagged Image File Format

Returns

String

If filename is not specified,  then the current wallpaper bitmap filename if successful.

String

If filename is specified,  then the previous wallpaper bitmap filename if successful.

None

If not successful, or on error.

Example

import rhinoscriptsyntax as rs

view = rs.CurrentView()

filename = rs.OpenFileName()

if filename and not rs.IsWallpaper(view):

    rs.Wallpaper(view, filename)

Also See

IsWallpaper

WallpaperGrayScale

WallpaperHidden