急急急!!!CRichEditCtrl 是否可以改变字体间距?

xing558969 2009-03-04 10:40:45
CHARFORMAT2 cf2;
memset(&cf2, 0, sizeof(CHARFORMAT2));
cf2.cbSize = sizeof(CHARFORMAT2);
cf2.dwMask = CFM_SPACING;
cf2.sSpacing = 10;
m_mTextContrl.SetSelectionCharFormat(cf2);
m_mTextContrl.SetDefaultCharFormat(cf2);
m_mTextContrl.SetWordCharFormat(cf2);

我用以上的代码来设置字体间距,但没有效果!!!了解的大虾过来帮忙啊
...全文
382 42 打赏 收藏 转发到动态 举报
写回复
用AI写文章
42 条回复
切换为时间正序
请发表友善的回复…
发表回复
lclichao2006 2009-07-17
  • 打赏
  • 举报
回复
支持一下楼主
lclichao2006 2009-03-10
  • 打赏
  • 举报
回复
学习一下,up
XXGGYYXX 2009-03-09
  • 打赏
  • 举报
回复
东软和大连华信的合并案如果成功将缔造中国
davidax 2009-03-08
  • 打赏
  • 举报
回复
you must use SetOptions before calling charformat & charformat2 methods.
davidax 2009-03-08
  • 打赏
  • 举报
回复
what's your richedit version ?!?

open rc file in notepad and or right click on it in solution explorer and click code view and write the line of richedit code here,

we can change the modulation of richedit but only available in version > 2

you can try loadlibrary(_T("MSFTEDIT.DLL")); to load richedit 4 or 5 and test your code again or write your original code here to help u as soon as possible
lclichao2006 2009-03-06
  • 打赏
  • 举报
回复
顶一下
  • 打赏
  • 举报
回复
[Quote=引用 33 楼 wugaofeng555 的回复:]
C/C++ code
PARAFORMAT2 pf;
pf.cbSize = sizeof(PARAFORMAT2);
pf.dwMask = PFM_NUMBERING | PFM_OFFSET;
pf.wNumbering = PFN_BULLET;//注意PFM_NUMBERING
pf.dxOffset = 10;
VERIFY(SetParaFormat(pf));
[/Quote]

之前我说的办法不行,
上面说的办法也不行,试过了
还有我试过改字体也不行

看来 RichEdit 是不支持这个功能, 试试别的控件吧
wugaofeng555 2009-03-06
  • 打赏
  • 举报
回复

PARAFORMAT2 pf;
pf.cbSize = sizeof(PARAFORMAT2);
pf.dwMask = PFM_NUMBERING | PFM_OFFSET;
pf.wNumbering = PFN_BULLET;//注意PFM_NUMBERING
pf.dxOffset = 10;
VERIFY(SetParaFormat(pf));
cht_1988 2009-03-06
  • 打赏
  • 举报
回复
啊我来也谢谢分享啊
  • 打赏
  • 举报
回复
mark
catoop 2009-03-06
  • 打赏
  • 举报
回复
看不懂,也要顶个
Q-Luo 2009-03-05
  • 打赏
  • 举报
回复
该类有不同的版本,你找找其它版本的dll看看...
xiaozhimeng 2009-03-05
  • 打赏
  • 举报
回复
关注
hujihong 2009-03-05
  • 打赏
  • 举报
回复
关注,一样的问题困扰
r123654 2009-03-05
  • 打赏
  • 举报
回复
你们 的 是 C++??
liwei222 2009-03-05
  • 打赏
  • 举报
回复
关注
mmhvsysl 2009-03-05
  • 打赏
  • 举报
回复
没有用过。
yangfeng66 2009-03-05
  • 打赏
  • 举报
回复
看不懂,也要顶个
mouse1984dog 2009-03-05
  • 打赏
  • 举报
回复
你看看微软的Text Object Model(TOM),我也没试过。
reezonew 2009-03-05
  • 打赏
  • 举报
回复
按照xhk_xhk方法试过以后还是不可以!!!请持续关注
加载更多回复(18)

7,540

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 VC.NET
社区管理员
  • VC.NET社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧