RhinoSync Type
All methods in Rhino.Scripting.dll are thread safe and can be called from any thread. However concurrent writing to Rhino Object Tables might corrupt its state. This class provides a way to run all UI methods on the UI thread. It tries to use the Fesh Editor UI thread if it is running. If you are not running from the Fesh Editor, it will use RhinoApp.MainWindow.Invoke.
Static members
Static member |
Description
|
Full Usage:
RhinoSync.ClearLog()
|
Clears the Fesh log window and the Rhino command history window. |
Full Usage:
RhinoSync.DoSync(func)
Parameters:
unit -> 'T
Returns: 'T
|
Evaluates a function on UI Thread.
|
Full Usage:
RhinoSync.DoSyncRedraw(func)
Parameters:
unit -> 'T
Returns: 'T
|
Evaluates a function on UI Thread. Also ensures that redraw is enabled and disabled afterwards again if it was disabled initially.
|
Full Usage:
RhinoSync.DoSyncRedrawHideEditor(func)
Parameters:
unit -> 'T
Returns: 'T
|
Evaluates a function on UI Thread. Also ensures that redraw is enabled and disabled afterwards again if it was disabled initially. Hides Fesh editor window if it exists. Shows it afterwards again
|
Full Usage:
RhinoSync.HideEditor()
|
Hide the WPF Window of currently running Fesh Editor. Or do nothing if not running in Fesh Editor. |
Full Usage:
RhinoSync.LogErrors
|
Set to false to disable the logging off errors to RhinoApp.WriteLine and the error stream (eprintfn). |
Full Usage:
RhinoSync.PrettyFormatters
Returns: ResizeArray<(obj -> string option)>
|
|
Full Usage:
RhinoSync.PrintColor(r) (g) (b) (s)
Parameters:
int
g : int
b : int
s : string
|
Prints in both RhinoApp.WriteLine and Console.WriteLine, or Fesh Editor with color if running. Red green blue text , NO new line
|
Full Usage:
RhinoSync.PrintnColor(r) (g) (b) (s)
Parameters:
int
g : int
b : int
s : string
|
Prints in both RhinoApp.WriteLine and Console.WriteLine, or Fesh Editor with color if running. Red green blue text , with new line
|
Full Usage:
RhinoSync.ShowEditor()
|
Show the WPF Window of currently running Fesh Editor. Or do nothing if not running in Fesh Editor. |
Full Usage:
RhinoSync.SyncContext
|
The SynchronizationContext of the currently Running Rhino Instance, This SynchronizationContext is loaded via reflection from the Fesh.Rhino plugin |