fontwrong.SetColor(255);

sel.MoveRight(COleVariant((short)1),COleVariant((short)(tempwrong)),COleVariant((short)1));
sel.MoveRight(COleVariant((short)1),COleVariant((short)1),COleVariant((short)0));    
    }
    else
    {tempwrong=-(tempwrong);
    sel.MoveRight(COleVariant((short)1),COleVariant((short)(tempwrong)),COleVariant((short)1));
    sel.MoveRight(COleVariant((short)1),COleVariant((short)1),COleVariant((short)0));
    sel.MoveRight(COleVariant((short)1),COleVariant((short)1),COleVariant((short)1));
    fontwrong.AttachDispatch(sel.GetFont());
    fontwrong.SetStrikeThrough(1);
     fontwrong.SetColor(255);
     sel.MoveLeft(COleVariant((short)1),COleVariant((short)(tempwrong)),COleVariant((short)1));
    sel.MoveLeft(COleVariant((short)1),COleVariant((short)1),COleVariant((short)0));
    }
    if (tempwrong==0)
    {fontwrong.AttachDispatch(sel.GetFont());
    fontwrong.SetStrikeThrough(1);
     fontwrong.SetColor(255);
    }
     fontwrong.ReleaseDispatch();
      wrongflag=0;
      }
      font.AttachDispatch (sel.GetFont());  
    
      sel.MoveLeft(COleVariant((short)1),COleVariant((short)1),COleVariant((short)0));
      
  }
   
  sel.MoveRight(COleVariant((short)1),COleVariant((short)m),COleVariant((short)1));
 sel.MoveRight(COleVariant((short)1),COleVariant((short)1),COleVariant((short)0));
   tempp=m;
  m=tempp+p;
  p=tempp;
  if (m>n) {m=3;p=1;}
      
}
if (1!=wrongflag)
{sel.MoveRight(COleVariant((short)1),COleVariant((short)m),COleVariant((short)1));
tempsum=int(fmod(double(tempsum),double(10)));
    
    switch (tempsum)
  { case 0: wf[0].line=55;break;
    case 1: wf[0].line=1;break;
    case 2: wf[0].line=3;break;
    case 3: wf[0].line=4;break;
    case 4: wf[0].line=6;break;
    case 5: wf[0].line=7;break;
    case 6: wf[0].line=9;break;
    case 7: wf[0].line=10;break;
    case 8: wf[0].line=11;break;
    case 9: wf[0].line=20;break;
  }
     
font.AttachDispatch (sel.GetFont());
font.GetUnderlineColor();
 font.GetUnderline();
 
if ((font.GetUnderline()!=wf[0].line))
    {
    
     sel.WholeStory();
    fontwrong.AttachDispatch(sel.GetFont());
     fontwrong.SetStrikeThrough(1);
     fontwrong.SetColor(255);
     fontwrong.ReleaseDispatch();
        wrongflag=0;
}
}
(4)如果检测到文档被篡改,软件会对文章内容画红线并且弹出提示框提示用户,如图3.5所示。
 
if (1!=wrongflag) {MessageBox("水印错误,文档已被篡改");}
fontwrong.ReleaseDispatch();
font.ReleaseDispatch();
sel.ReleaseDispatch();

图3.5 文档错误提示
4    系统性能测试
4.1    水印嵌入测试
用户打开要嵌入的WORD文档后可以输入任意1-99范围内的密钥,然后生成对应水印如图4.1所示。
上一篇:基于webform的在线考试系统+用例图+文献综述
下一篇:Ford–Fulkerson算法铁路运输系统中车辆流问题的研究

基于MOODLE平台的在线交互式学习设计

基于离散事件系统Petri网模型的可达图研究

基于高斯过程动态模型的时序数据恢复方法

基于深度学习的目标识别算法研究

MATLAB基于流形学习与神经网络的预测建模

基于SNA的唐诗关系分析

基于启发式算法的智能路径规划研究

林业机械作业中的安全性问题【2230字】

适合宝妈开的实体店,适...

浅谈动画短片《天降好运》中的剧本创作

淮安市老漂族心理与休闲体育现状的研究

人事管理系统开题报告

弹道修正弹实测弹道气象数据使用方法研究

小学《道德与法治》学习心得体会

大学生就业方向与专业关系的研究

紫陵阁

组态王文献综述