在 RTF 中使用表格 [英] Using Tables in RTF

查看:27
本文介绍了在 RTF 中使用表格的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要在 RTF 文件中创建一个表.但是我不熟悉RTF.以下是这些 RTF 文件应该替换的文本文件示例:

I need to create a table in an RTF file. However I am not familiar with RΤF. Here is an example of a text file that these RTF files are supposed to replace:

                               GENERAL JOURNAL
                                                                        Page 1

Date     Description                              Post Ref   Debit      Credit  
------------------------------------------------------------------------------
2011
Dec 1    Utilities Expense                          512      250.00
            Cash                                    111                 250.00
               Paid electric bill for November,
               Check No. 1234

    2    Cash                                       111       35.00
            Accounts Receivable / Customer Name     115/√                30.00
            Interest Income                         412                   5.00
               Receipt of payment on account
               from Customer, Check No. 5678

         . . .

表格应该有边框,但我也不知道如何做到这一点.一些单元格的底部必须有特殊的边框,如该文件所示:

The table is supposed to have borders, but I don't know how to do this either. Some cells have to have special borders on the bottom as in this file:

                                 Company Name
                        Schedule of Accounts Receivable
                               December 31, 2011

Name                                                                   Balance
------------------------------------------------------------------------------
Adams, John                                                             354.24
Jefferson, Thomas                                                        58.35
Washington, George                                                      754.58
                                                                      --------
                                                                       1167.17
                                                                      ========

我知道 \cell\row 等,但我不知道如何正确使用它们,因为我发现的文档不是很好的.请帮忙.

I am aware of the \cell, \row etc., but I cannot figure out how to use them properly as the documentation that I have found is not very good. Please help.

推荐答案

这个站点很有用:http://www.pindari.com/rtf3.html

{\rtf1\ansi\deff0
\trowd
\cellx1000
\cellx2000
\cellx3000
\intbl cell 1\cell
\intbl cell 2\cell
\intbl cell 3\cell
\row
} 

这将给出:

---------------------------
|cell 1 | cell 2 | cell 3 |  
---------------------------

一行用 \trowd ... \row

每个单元格以 \cell

\cellx 以缇为单位确定对应单元格的右侧

\cellx determines the right side of the corresponding cell in twips

这篇关于在 RTF 中使用表格的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆