private void OnButtonClick(object sender, EventArgs e)
        {
            var vi  = new ViewInfo(RhinoDoc.ActiveDoc.Views.ActiveView.ActiveViewport);
            var vpi = vi.Viewport;

            var vud = vpi.UserData.Find(typeof(ViewportSettings)) as ViewportSettings;

            if (vud == null)
            {
                var nvud = new ViewportSettings();
                vpi.UserData.Add(nvud);
            }
            ViewDataChanged?.Invoke(this, EventArgs.Empty);
        }
예제 #2
0
 private void AddUserData_ViewDataChanged(object sender, EventArgs e)
 {
     ViewDataChanged?.Invoke(sender, e);
 }