【学习】ABAP OLE 对EXCEL的处理
原文:http://blog.sina.com.cn/s/blog_7229b9c00100opx2.html
----------------------------------------------------------------------------
REPORT ZVR013.
INCLUDE OLE2INCL.
DATA: GS_EXCEL TYPE OLE2_OBJECT,
GS_WBOOKLIST TYPE OLE2_OBJECT,
GS_APPLICATION TYPE OLE2_OBJECT,
GS_WBOOK TYPE OLE2_OBJECT,
GS_ACTIVESHEET TYPE OLE2_OBJECT,
GS_SHEETS TYPE OLE2_OBJECT,
GS_NEWSHEET TYPE OLE2_OBJECT,
GS_CELL1 TYPE OLE2_OBJECT,
GS_CELL2 TYPE OLE2_OBJECT,
GS_CELLS TYPE OLE2_OBJECT,
GS_FONT TYPE OLE2_OBJECT,
GS_PAGE TYPE OLE2_OBJECT,
GS_RANGE TYPE OLE2_OBJECT,
GS_BORDERS TYPE OLE2_OBJECT.
DATA: GV_SHEET_NAME() TYPE C.
DATA: GV_OUTER_INDEX LIKE SY-INDEX.
DATA: GV_INTEX() TYPE C.
DATA: GV_LINE_CNTR TYPE I. "LINE COUNTER
DATA: GV_LINNO TYPE I. "LINE NUMBER
DATA: GV_COLNO TYPE I. "COLUMN NUMBER
DATA: GV_VALUE TYPE I. "DATA
DATA: X1 TYPE P, X2 TYPE P, Y1 TYPE P, Y2 TYPE P.
DATA: VALUE(),VALUE1().
DATA: NAME(),SIZE().
DATA: BOLD TYPE P, UNDERLINE TYPE P, ALIGNMENT TYPE P.
DATA: ROW TYPE P VALUE , LINE TYPE P VALUE . "循环次数
DATA: ROW1 TYPE P,LINE1 TYPE P.
DATA: QUANTITY(),AMOUNT().
DATA: ROWHEIGHT(),COLUMNWIDTH().
DATA: PAGE TYPE P, PG_INDEX TYPE P.
*-----------------------------------------------------------
*-----------------------------------------------------------
CREATE OBJECT GS_EXCEL 'EXCEL.APPLICATION'.
SET PROPERTY OF GS_EXCEL 'VISIBLE' = .
GET PROPERTY OF GS_EXCEL 'WORKBOOKS' = GS_WBOOKLIST.
GET PROPERTY OF GS_WBOOKLIST 'APPLICATION' = GS_APPLICATION.
SET PROPERTY OF GS_APPLICATION 'SHEETSINNEWWORKBOOK' = .
CALL METHOD OF GS_WBOOKLIST 'ADD' = GS_WBOOK.
GET PROPERTY OF GS_APPLICATION 'ACTIVESHEET' = GS_ACTIVESHEET.
SET PROPERTY OF GS_ACTIVESHEET 'NAME' = GV_SHEET_NAME.
GET PROPERTY OF GS_ACTIVESHEET 'PAGESETUP' = GS_PAGE.
SET PROPERTY OF GS_PAGE 'TOPMARGIN' = ''.
SET PROPERTY OF GS_PAGE 'BOTTOMMARGIN' = ''.
SET PROPERTY OF GS_PAGE 'LEFTMARGIN' = ''.
SET PROPERTY OF GS_PAGE 'RIGHTMARGIN' = ''. *--FORMATTING THE TITLE
FORM FORMAT USING GS_CELL1 VALUE NAME SIZE BOLD ALIGNMENT UNDERLINE.
CONDENSE VALUE.
CONDENSE NAME.
CONDENSE SIZE.
GET PROPERTY OF GS_CELL1 'FONT' = GS_FONT .
SET PROPERTY OF GS_FONT 'NAME' = NAME.
SET PROPERTY OF GS_FONT 'SIZE' = SIZE.
SET PROPERTY OF GS_FONT 'BOLD' = BOLD. "NOT BOLD
SET PROPERTY OF GS_FONT 'ITALIC' = ''. "NOT ITALIC
SET PROPERTY OF GS_FONT 'UNDERLINE' = UNDERLINE. "NOT UNDERLINED
SET PROPERTY OF GS_CELL1 'WRAPTEXT' = .
SET PROPERTY OF GS_CELL1 'HORIZONTALALIGNMENT' = ALIGNMENT.
" && 水平方向 2左对齐,3居中,4右对齐
SET PROPERTY OF GS_CELL1 'VERTICALALIGNMENT' = .
"&& 垂直方向 1靠上 ,2居中,3靠下
SET PROPERTY OF GS_CELL1 'NUMBERFORMATLOCAL' = '@'.
"&& 设置数据格式
SET PROPERTY OF GS_CELL1 'VALUE' = VALUE.
ENDFORM. "FORMAT
*------------------------------
*该函数用来合并EXCEL单元格
*------------------------------
FORM MERGED USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
ENDFORM. "MERGED
*---------------------------------
*生成四周有边框的单元格
*---------------------------------
FORM MERGED_BORDERS USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
GET PROPERTY OF GS_CELLS 'BORDERS' = GS_RANGE .
SET PROPERTY OF GS_RANGE 'WEIGHT' = ''.
SET PROPERTY OF GS_RANGE 'LINESTYLE' = ''.
FREE OBJECT GS_RANGE.
ENDFORM. "MERGED
*--------------------------------------
*---------------------------------
*生成左右有边框的单元格
*---------------------------------
FORM SIDES_BORDERS USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS. CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
*& (其中BORDERS参数:1-左、2-右、3-顶、4-底、5-斜、6-斜/; *&LINESTYLE值:1与7-细实、2-细虚、4-点虚、9-双细实线) SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS.
ENDFORM. "MERGED
*---------------------------------
FORM LEFT_BORDERS USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS.
ENDFORM. "MERGED
FORM RIGHT_BORDERS USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS.
ENDFORM. "MERGED *---------------------------------
*生成BOTTOM有边框的单元格
*---------------------------------
FORM BOTTOM_BORDERS USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS.
ENDFORM. "MERGED FORM BOTTOM_LINES USING X1 Y1 X2 Y2.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
CALL METHOD OF GS_CELLS 'BORDERS' = GS_BORDERS
EXPORTING
# = ''.
SET PROPERTY OF GS_BORDERS 'LINESTYLE' = ''.
SET PROPERTY OF GS_BORDERS 'WEIGHT' = .
FREE OBJECT GS_BORDERS.
ENDFORM. "MERGED *-------------------------------------------------
*设置行高和列宽。
FORM ROW_COLUMN USING X1 Y1 X2 Y2 ROWHEIGHT COLUMNWIDTH.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
GET PROPERTY OF GS_CELLS 'ROWS' = GS_BORDERS.
SET PROPERTY OF GS_BORDERS 'ROWHEIGHT' = ROWHEIGHT.
GET PROPERTY OF GS_CELLS 'COLUMNS' = GS_RANGE .
SET PROPERTY OF GS_RANGE 'COLUMNWIDTH' = COLUMNWIDTH.
FREE OBJECT GS_BORDERS.
FREE OBJECT GS_RANGE.
ENDFORM. "MERGED
FORM ROWHEIGHT USING X1 Y1 X2 Y2 ROWHEIGHT.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
GET PROPERTY OF GS_CELLS 'ROWS' = GS_BORDERS.
SET PROPERTY OF GS_BORDERS 'ROWHEIGHT' = ROWHEIGHT.
* GET PROPERTY OF GS_CELLS 'COLUMNS' = GS_RANGE .
* SET PROPERTY OF GS_RANGE 'COLUMNWIDTH' = COLUMNWIDTH.
FREE OBJECT GS_BORDERS.
FREE OBJECT GS_RANGE.
ENDFORM. "MERGED FORM COLUMNWIDTH USING X1 Y1 X2 Y2 COLUMNWIDTH.
*--SELECTING CELL AREA TO BE MERGED.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'SELECT'.
*--MERGING
CALL METHOD OF GS_CELLS 'MERGE' .
* GET PROPERTY OF GS_CELLS 'ROWS' = GS_BORDERS.
* SET PROPERTY OF GS_BORDERS 'ROWHEIGHT' = ROWHEIGHT.
GET PROPERTY OF GS_CELLS 'COLUMNS' = GS_RANGE .
SET PROPERTY OF GS_RANGE 'COLUMNWIDTH' = COLUMNWIDTH.
FREE OBJECT GS_BORDERS.
FREE OBJECT GS_RANGE.
ENDFORM. "MERGED
********************************************************
FORM PAGES USING L_FILE X Y.
X1 = .
Y1 = .
X2 = X.
Y2 = Y.
*DO PAGE TIMES.
*_-CREATE EXCEL
CONCATENATE 'SHEET' '' INTO GV_SHEET_NAME.
CREATE OBJECT GS_EXCEL 'EXCEL.APPLICATION'.
SET PROPERTY OF GS_EXCEL 'VISIBLE' = .
GET PROPERTY OF GS_EXCEL 'WORKBOOKS' = GS_WBOOKLIST.
*----COPY
CALL METHOD OF GS_WBOOKLIST 'OPEN' = GS_RANGE
EXPORTING
# = L_FILE.
CALL METHOD OF GS_EXCEL 'WORKSHEETS' = GS_BORDERS
EXPORTING # = .
CALL METHOD OF GS_BORDERS 'ACTIVATE'.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# =
# = .
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X
# = Y.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'COPY'.
*----PASTESPECIAL
*-CREATE
CALL METHOD OF GS_WBOOKLIST 'ADD' = GS_WBOOK.
GET PROPERTY OF GS_APPLICATION 'ACTIVESHEET' = GS_ACTIVESHEET.
SET PROPERTY OF GS_ACTIVESHEET 'NAME' = GV_SHEET_NAME.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# =
# = .
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X
# = Y.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'PASTESPECIAL'.
CALL METHOD OF GS_CELLS 'COPY'.
CALL METHOD OF GS_RANGE 'ACTIVATE'.
CALL METHOD OF GS_RANGE 'CLOSE'.
CALL METHOD OF GS_ACTIVESHEET 'ACTIVATE'.
ENDFORM.
*-------------------------------------------------
FORM PAGES1 USING X Y.
DO PAGE TIMES.
X1 = X1 + X.
Y1 = .
X2 = X2 + X.
Y2 = Y.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# =
# = .
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X
# = Y.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'COPY'.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL1
EXPORTING
# = X1
# = Y1.
CALL METHOD OF GS_EXCEL 'CELLS' = GS_CELL2
EXPORTING
# = X2
# = Y2.
CALL METHOD OF GS_EXCEL 'RANGE' = GS_CELLS
EXPORTING
# = GS_CELL1
# = GS_CELL2.
CALL METHOD OF GS_CELLS 'PASTESPECIAL'.
ENDDO.
ENDFORM.
if p_file is initial.
message '请输入导入文件的路径' type 'I'.
leave to transaction sy-tcode.
endif.
data: begin of i_excel occurs 0.
* ROW(4) TYPE N,
* COL(4) TYPE N,
* VALUE(150),
include structure alsmex_tabline.
data: end of i_excel.
data: l_answer(1) type c.
data: l_column type i.
field-symbols: <fs>.
data: l_pathname like rlgrap-filename.
data:
c_begin_row type i value 4, "Beginning row of excel file
c_begin_col type i value 2, "Beginning column of excel file
c_end_row type i value 10000, "Ending row of excel file
c_end_col type i value 11. "Ending column of excel file
move p_file to l_pathname.
call function 'ALSM_EXCEL_TO_INTERNAL_TABLE'
exporting
filename = l_pathname
i_begin_col = c_begin_col
i_begin_row = c_begin_row
i_end_col = c_end_col
i_end_row = c_end_row
tables
intern = i_excel
exceptions
inconsistent_parameters = 1
upload_ole = 2
others = 3.
【学习】ABAP OLE 对EXCEL的处理的更多相关文章
- 2018年,请不要再使用OLE生成EXCEL文件
输出EXCEL文件是ABAP开发工作中的常见需求,为了学习相关技术,我翻译过一篇文章:使用OLE2对象创建EXCEL文件,并且一度乐在其中. 最近几个月,经过与若干EXCEL打印程序的艰苦斗争,以及对 ...
- 【ABAP系列】SAP ABAP DOI展示EXCEL或WORD
公众号:SAP Technical 本文作者:matinal 原文出处:http://www.cnblogs.com/SAPmatinal/ 原文链接:[ABAP系列]SAP ABAP DOI展示EX ...
- 一步步实现ABAP后台导入EXCEL到数据库【3】
在一步步实现ABAP后台导入EXCEL到数据库[2]里,我们已经实现计划后台作业将数据导入数据库的功能.但是,这只是针对一个简单的自定义结构的导入程序.在实践应用中,面对不同的表.不同的导入文件,我们 ...
- 一步步实现ABAP后台导入EXCEL到数据库【1】
在SAP的应用当中,导入.导出EXCEL文件的情况是一个常见的需求,有时候用户需要将大量数据定期导入到SAP的数据库中.这种情况下,使用导入程序在前台导入可能要花费不少的时间,如果能安排导入程序为后台 ...
- OLE操作Excel编译错误处理
Excel在公司用的很多,而这个东西我用的不是很好,就想用程序来处理,遇到很多错误.这几天研究了下OLE操作Excel.环境:VS2008 SP1+Excel 2007 加入OLE Type Li ...
- (原创)带模板的OLE输出EXCEL
其实带模板的OLE输出EXCEL就是将要输出的EXCEL中一些拥有固定值(如标题,表头行等)的单元格先填充好数据和设置好格式后作为模板上传到SAP 中.这样后续在输出EXCEL时只需从SAP中将模板下 ...
- ABAP OLE
OLE DATA: excel TYPE ole2_object, workbook TYPE ole2_object, sheet TYPE ole2_object, cell TYPE ole2_ ...
- ABAP,学习不一样的EXCEL导出----XLSX Workbench
这个工具是在查找ABAP导出EXCEL资料的时候发现,是国外的一位大牛自己开发的开源项目,体验了一番,确实很好用. 工具特点: No ABAP Programming Skills are requi ...
- ABAP ole方式对EXCEL进行操作
DATA: excel TYPE ole2_object, workbook TYPE ole2_object, sheet TYPE ole2_object, ...
随机推荐
- swift swizzle
SWIZZLE 由 王巍 (@ONEVCAT) 发布于 2015/09/30 Swizzle 是 Objective-C 运行时的黑魔法之一.我们可以通过 Swizzle 的手段,在运行时对某些方法的 ...
- UIlabel - 富文本属性
1.NSKernAttributeName: @10 调整字句 kerning 字句调整 2.NSFontAttributeName : [UIFont systemFontOfSize:_fontS ...
- 图表插件——Highcharts插件的使用(一柱状图)
1.下载Highcharts插件 官方下载网址:http://www.highcharts.com/download 2.引入需要的js文件 <script src="~/Script ...
- Visual Studio快捷键小结
工欲善其事必先利其器,这句话相信大家都听说过.利其器,就是我们先得有个神器,神器就是VS(号称宇宙第一IDE),有了神奇不会用也是白搭,就像你有了倚天剑和屠龙刀你不会使,它也就是废铁(假设它们是铁做的 ...
- Android sqlite 数据库在java代码中的增删改查
private void queryPerson(PersonSQLiteOpenHelper personSQLiteOpenHelper) { SQLiteDatabase sqLiteDatab ...
- 使用HttpURLConnection向服务器发送post和get请求
一.使用HttpURLConnection向服务器发送get请求 1.向服务器发送get请求 @Test publicvoid sendSms() throws Exception{ String m ...
- BeRoTinyPascal
https://github.com/BeRo1985/berotinypascal https://github.com/thachngopl/berotinypascal
- HttpResponseCache 网络缓存使用
Caches HTTP and HTTPS responses to the filesystem so they may be reused, saving time and bandwidth. ...
- Android 使用LinearLayout.getChildAt(i)获取一个线性布局的view,并实现content中实现方法
1.定义接口content的方法,如ok,cancle; 2.在View的处理类myview中实现content的方法. 3.通过contently.getChildAt(i)的方法获得View v; ...
- Serif和Sans-serif字体的区别(转)
在西方国家罗马字母阵营中,字体分为两大种类:Sans Serif和Serif,打字机体虽然也属于Sans Serif,但由于是等宽字体,所以另外独立出Monospace这一种类,例如在Web中,表示代 ...