Prod.: Engine, ver.: 6, ID: 60000369, HowTo : I do not want to display the Selecting crossing green and window blue rectangle and selected entities not to be added in grip selections.

HowTo : I do not want to display the Selecting crossing green and window blue rectangle and selected entities not to be added in grip selections.

Article60000369
TypeHowTo
ProductEngine
Version6
Date Added1/4/2008
Submitted byyinzd
Keywords

Subject

I do not want to display the Selecting crossing green and window blue rectangle and selected entities not to be added in grip selections.

Summary

I do not want to display the Selecting crossing green and window blue rectangle and selected entities not to be added in grip selections.

Solution

Example in C# with vdFrameControl in a application Form:

using System;

using System.Collections.Generic;

using System.ComponentModel;

using System.Data;

using System.Drawing;

using System.Text;

using System.Windows.Forms;

using VectorDraw.Professional.vdCollections;

namespace WindowsApplication1

{

public partial class Form1 : Form

{

public Form1()

{

InitializeComponent();

}

protected override void OnLoad(EventArgs e)

{

base.OnLoad(e);

//do not show the green and blue selecting colors

vdFramedControl1.BaseControl.ActiveDocument.GlobalRenderProperties.SelectingCrossColor = Color.Empty;

vdFramedControl1.BaseControl.ActiveDocument.GlobalRenderProperties.SelectingWindowColor = Color.Empty;

vdFramedControl1.BaseControl.ActiveDocument.OnFilterFigure += new VectorDraw.Professional.vdObjects.vdDocument.FilterFigureEventHandler(ActiveDocument_OnFilterFigure);

}

void ActiveDocument_OnFilterFigure(object sender, VectorDraw.Professional.Constants.VdConstFilterFig JobId, VectorDraw.Professional.vdPrimaries.vdFigure fig, ref bool cancel)

{

//do not add the entities in default vdraw grip selections.

if (JobId != VectorDraw.Professional.Constants.VdConstFilterFig.FILTERFIG_SELECT) return;

if (fig == null) return;

vdSelection gripset = sender as vdSelection;

if (gripset == null) return;

if (!gripset.Name.StartsWith("VDGRIPSET")) return;

cancel = true;

//throw new Exception("The method or operation is not implemented.");

}

}

}