写了一个动态修改线的样式的方法,其他样式使用setstyle修改都没问题,只是修改outline描边的时候,setstyle线的outlin为true可以改变,但是改为false就不生效了
refreshLineStyle2() {
let self=this;
console.log(self.lineFrom.outline);
let style = {
clampToGround: self.lineFrom.clampToGround,
color: self.lineFrom.color,
opacity: self.lineFrom.opacity,
outlineColor: self.lineFrom.outlineColor,
width:15,
outlineWidth: self.lineFrom.outlineWidth,
outlineOpacity: self.lineFrom.outlineOpacity,
distanceDisplayCondition: !self.lineFrom.clampToGround,
distanceDisplayCondition_far: self.lineFrom.floor,
distanceDisplayCondition_near: 0,
outline:false,
}
self.nowPointEntitles.setStyle(style)
},