in case somebody using it, added a new project "IHL_CsR22ExtApp0" for Sketchup 2018/2017 x64 with ruby 22
Latest posts made by icehuli
-
RE: Extension using c#
-
RE: VCB and Shortcut Keys
additional observation:
If onKeyDown or onKeyUp returns true then onCancel is not triggered. It is blocked by onKeyDown/onKeyUp as well. -
Fresh active_view when click on menu item
Hi All,
any one knows how to refresh the active_view immediately when one click on a menu button while the mouse does not entering the view window.
What I try to do is to change the font size of view.draw_text by click on the menu buttons.
Currently I can only see the effects after I move the mouse entering the view area. It is not a big issue. But it would be great that I can update the view immediately once I click on the menu button.Thanks
I have tried:
Sketchup.active_model.active_view.refresh
It doesn't work.
-
RE: [Code] Skew Transformation from axes
@fredo6 said:
...and there is the magic formula by thomthom to check if two faces are coplanar (actually have parallel planes)
face1.normal % face2.normal > 0.9999999991
Fredo
I have never known this operator "%" on vectors. Fredo, could you explain to me how it works....
-
RE: Win32ole access violation
I think you need to use another thread for the WinForm windows, e.g MessageBox. I checked the following code. It works. It actually makes more sense to let the WinForm window in a separate thread other than the Sketchup's thread.
Imports System.Windows.Forms Public Class MyFunctions Private Sub showMessage(ByVal msg As String) MessageBox.Show(msg) End Sub Public Function AddMyValues() Dim Result As Double Result = 20 Dim t1 As New Threading.Thread(AddressOf showMessage) t1.Start(Result) Return Result End Function End Class
-
RE: Determine Whether a Point is 'in' a Volume
is there a better solution for this now?
-
RE: Ruby 2.0.0 Threads in SU | how to keep a subthread running?
@sr20vet said:
Yep, I've taken the native threads path. Got the thread running, got even an http server running in that thread. But now, GIL is killing me. Can't call ruby from that second native thread...
May I ask what exactly you are trying to do? I think you can call ruby from that second native thread.
One important point is that the ruby function needs to be involved in the ruby thread, i.e. the SU thread. So in the c-extension there should be two threads, one is the same SU thread, the other is your second native thread. All ruby codes need to run within the SU thread. -
RE: Load classification system via ruby code
Thanks Aerilius,
Thanks tt_su,I am waiting for the next release.
Anyway it is nice to see that SketchUp is on the way to BIM.
I have figured out how to add a classification to an entity, just in case that anyone would like to try the [highlight=#ffff00:3oppyo7z]undocumented[/highlight:3oppyo7z] API function "add_classification
".group.add_classification 'IFC 2x3', 'ifc;IfcBeam'
-
Load classification system via ruby code
Hi all,
Does any know if it is possible to load classification system into a model via Ruby Code? If yes, how? Thanks!
-
RE: Extension using c#
@dan rathbun said:
@icehuli said:
The C# stuff works on SketchUp 2014 with Ruby 2.0.0
ALL tutorials should show ALL objects being created INSIDE an Author's toplevel module.
We usually use the module name
Author
orAuthorNamespace
orCompanyNamespace
, etc., do denote that the end user should replace that name with their own toplevel module name.Only Ruby and the API (in rare cases,) should ever create classes at the toplevel (aka
TOPLEVEL_BINDING
.)Thanks for the reminding.