修正错误的拼写. explode

pull/60/head
ChenX 7 years ago
parent 3e521bff7a
commit 5e89c30f0b

@ -35,11 +35,11 @@ export class DrawRegion implements Command
{
if (en.IsClose)
{
let reg = new Region(en.Export());
let reg = new Region(en.Explode());
app.m_Database.ModelSpace.Append(reg);
}
else
lines.push(...en.Export());
lines.push(...en.Explode());
}
else if (en instanceof Curve)
{

@ -4,7 +4,7 @@ import { PromptStatus } from "../Editor/PromptResult";
import { app } from "../ApplicationServices/Application";
export class Command_Export implements Command
export class Command_Explode implements Command
{
async exec(ss: SelectSet)
{
@ -19,7 +19,7 @@ export class Command_Export implements Command
for (let en of ss.SelectEntityList)
{
let ens = en.Export();
let ens = en.Explode();
en.Erase();
for (let e of ens)

@ -69,7 +69,7 @@ export class AlignedDimension extends Dimension
this.m_Oblique = v;
this.Update();
}
Export()
Explode()
{
//TODO:箭头实体
let [ept1, ept2, extEndPt1, extEndPt2, scaleSPt, scaleEPt] = this.GetDimPts();

@ -94,7 +94,7 @@ export class LineAngularDimension extends Dimension
{
super.TextString = v;
}
Export()
Explode()
{
let { lineStartPt, lineEndPt } = this.getDimLineData();
let { arcStartPt, arcEndPt, extSpt, extEpt, scaleSPt, scaleEPt, bul } = this.getDimArcData();

@ -18,7 +18,7 @@ export class Command_DimTest implements Command
let dim = new AlignedDimension(new Vector3(), new Vector3(5), new Vector3(1, 3), "123");
dim.GetSnapPoints()
app.m_Database.ModelSpace.Append(dim);
let cus = dim.Export();
let cus = dim.Explode();
cus.forEach(cu =>
{
app.m_Database.ModelSpace.Append(cu);

@ -49,7 +49,7 @@ export class Entity extends CADObject
* @returns {Entity[]}
* @memberof Entity
*/
Export(): Entity[] { return [] }
Explode(): Entity[] { return [] }
/**
* .

@ -224,12 +224,12 @@ export class Polyline extends Curve
* . 线,
*
* @param {Vector3} pt
* @returns {number}
* @returns {number}
* @memberof Polyline
*/
GetParamAtPoint(pt: Vector3): number
{
let cus = this.Export();
let cus = this.Explode();
if (cus.length === 0) return NaN;
for (let i = 0; i < cus.length; i++)
{
@ -263,12 +263,11 @@ export class Polyline extends Curve
return pt.distanceToSquared(this.StartPoint) < pt.distanceToSquared(this.EndPoint) ?
startParam : endParam;
}
return NaN;
}
GetParamAtDist(dist: number): number
{
let cus = this.Export();
let cus = this.Explode();
for (let i = 0; i < cus.length; i++)
{
let cu = cus[i];
@ -724,7 +723,7 @@ export class Polyline extends Curve
*
* @memberof Polyline
*/
Export(): Curve[]
Explode(): Curve[]
{
let exportCus: Curve[] = [];
for (let i = 0; i < this.EndParam; i++)

@ -23,7 +23,7 @@ import { DrawText } from '../Add-on/DrawText';
import { DrawCircle0 } from '../Add-on/DrawZeroCircle';
import { Entsel } from '../Add-on/Entsel';
import { Command_Erase } from '../Add-on/Erase';
import { Command_Export } from '../Add-on/Export';
import { Command_Explode } from '../Add-on/Explode';
import { Command_Extend } from '../Add-on/Extends';
import { CommandFillet } from '../Add-on/Fillet';
import { Command_GenerateCode } from '../Add-on/GenerateCode';
@ -147,7 +147,7 @@ export function registerCommand()
/*******test ↓↓↓*********/
commandMachine.RegisterCommand("tt", new Command_PLTest());
commandMachine.RegisterCommand("tt2", new Command_INsTest());
commandMachine.RegisterCommand("x", new Command_Export());
commandMachine.RegisterCommand("x", new Command_Explode());
commandMachine.RegisterCommand("close", new Command_ClosePt());
//用于测试包围盒
commandMachine.RegisterCommand("box", new Command_TestBox());

@ -238,11 +238,11 @@ export function IntersectLineAndLine(l1: Line, l2: Line, extType: IntersectOptio
export function IntersectPolylineAndCurve(pl: Polyline, cu: Curve, extType: IntersectOption): Vector3[]
{
let cus: Curve[] = pl.Export();
let cus: Curve[] = pl.Explode();
let cus2: Curve[];
if (cu instanceof Polyline)
cus2 = cu.Export()
cus2 = cu.Explode()
else
cus2 = [cu];

Loading…
Cancel
Save