Commit f25f861e authored by 李俊赕's avatar 李俊赕

图片绘制微调

parent 38e01ac7
......@@ -10,7 +10,7 @@
src="/static/photo/icon-setting.png"></cover-image>
</cover-view>
</cover-view>
<camera class="camera-box" v-if="cameraChange&&!standardShow" :device-position="cameraInfo.devicePosition"
<camera class="camera-box" v-if="cameraChange" v-show="!standardShow" :device-position="cameraInfo.devicePosition"
:flash="cameraInfo.flash" :style="{'height':cameraHeight + 'rpx'}" @error="cameraError">
<cover-view class="mark-box">
<cover-view class="txt big" >{{titleTxt}}</cover-view>
......@@ -28,7 +28,7 @@
</cover-view>
<canvas canvas-id="canvas" id="photoCanvas" class="canvas"
:style="{'width':750 + 'rpx','height': cameraHeight + 'rpx'}"></canvas>
<view v-if="standardShow" class="page-mask" :z-index="10000">
<view v-show="standardShow" class="page-mask" :z-index="10000">
<photo-standard :currentItem="currentItem" />
<view class="btn-close" @click="closeShadow">
<image class="icon icon-close" mode="aspectFit" src="/static/photo/icon-close.png">
......@@ -362,8 +362,8 @@
//加入 水印文字
for (let i = settingTxtArr.length-1; i >=0; i--) {
txtHeight = 18
canvas.setFontSize(14)
txtHeight = 20
canvas.setFontSize(16)
canvas.setFillStyle('#f2f2f2')
let txt = settingTxtArr[i]
// if(txt.length>14){
......@@ -386,9 +386,9 @@
canvas.setFillStyle('#f2f2f2')
// canvas.setTextAlign('center')
if(title.length>14){
canvas.fillText(title.substr(14,14), 10, canvasHeight - txtHeight * h++);
canvas.fillText(title.substr(14,14), 10, canvasHeight - txtHeight * h++ + 20);
}
canvas.fillText(title.substr(0,14), 10, canvasHeight - txtHeight * h++ - titleHeight/2);
canvas.fillText(title.substr(0,14), 10, canvasHeight - txtHeight * h++ - titleHeight/2 + 10);
}
if(this.waterSetting && this.waterSetting.mid_text){
//加入 水印图片
......@@ -450,8 +450,7 @@
let hour = (d.getHours() < 10) ? ("0" + d.getHours()) : d.getHours();
let min = (d.getMinutes() < 10) ? ("0" + d.getMinutes()) : d.getMinutes();
let sec = (d.getSeconds() < 10) ? ("0" + d.getSeconds()) : d.getSeconds();
let now = year + "年" + month + "月" + date + "日 " + hour + ":" + min + ":" + sec + "(星期" + days[day] +
")";
let now = year + "年" + month + "月" + date + "日 " + hour + ":" + min + ":" + sec ;
return now
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment