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.
rhinoscriptsyntax.Wallpaper(view=None, filename=None)
rhinoscript.view.Wallpaper(view=None, filename=None)
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:
|
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. |
import rhinoscriptsyntax as rs
view = rs.CurrentView()
filename = rs.OpenFileName()
if filename and not rs.IsWallpaper(view):
rs.Wallpaper(view, filename)