📄 gridsettings.html
字号:
section.setPageSetup(pageSetup); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="setHorizontalSpacing(double)"><!-- --></A><H3>
setHorizontalSpacing</H3>
<PRE>
public void <B>setHorizontalSpacing</B>(double spacing)</PRE>
<DL>
<DD>设置水平网格线之间的间距(默认取磅值)。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>spacing</CODE> - 水平网格线之间的间距,范围在0.05到1584磅之间 说明:set方法的参数默认取磅值,如果要用其他的度量单位(英寸、厘米、毫米、十二点活字), 可以用 application.util.Utilities.otherToPoint(double, int)方法将其他度量单位转换为磅值后再调用相应的设置方法。 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setHorizontalSpacing(30); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当范围在0.05到1584磅之外时,抛出参数越界异常</DL>
</DD>
</DL>
<HR>
<A NAME="setHorizontalStart(double)"><!-- --></A><H3>
setHorizontalStart</H3>
<PRE>
public void <B>setHorizontalStart</B>(double start)</PRE>
<DL>
<DD>设置水平网格的起点(默认取磅值)。 说明:只有在不使用页边距状态下此方法才有效。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>start</CODE> - 水平网格的起点,范围在0到1584磅之间 说明:set方法的参数默认取磅值,如果要用其他的度量单位(英寸、厘米、毫米、十二点活字), 可以用 application.util.Utilities.otherToPoint(double, int)方法将其他度量单位转换为磅值后再调用相应的设置方法。 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setUsePageMarge(false); settings.setHorizontalStart(10.0f); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当使用页边距状态下,此方法抛出异常
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当范围在0到1584磅之外时,抛出参数越界异常</DL>
</DD>
</DL>
<HR>
<A NAME="setSnapToGrid(boolean)"><!-- --></A><H3>
setSnapToGrid</H3>
<PRE>
public void <B>setSnapToGrid</B>(boolean snaped)</PRE>
<DL>
<DD>设置网格是否与对象对齐。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>snaped</CODE> - 网格是否与对象对齐 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setSnapToGrid(true); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="setUsePageMarge(boolean)"><!-- --></A><H3>
setUsePageMarge</H3>
<PRE>
public void <B>setUsePageMarge</B>(boolean using)</PRE>
<DL>
<DD>设置是否使用页边距。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>using</CODE> - 是否使用页边距 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setUsePageMarge(true); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="setVerticalLineVisible(boolean)"><!-- --></A><H3>
setVerticalLineVisible</H3>
<PRE>
public void <B>setVerticalLineVisible</B>(boolean showing)</PRE>
<DL>
<DD>设置垂直网格是否显示。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>showing</CODE> - 垂直网格是否显示 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setVerticalLineVisible(true); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre></DL>
</DD>
</DL>
<HR>
<A NAME="setVerticalSpacing(double)"><!-- --></A><H3>
setVerticalSpacing</H3>
<PRE>
public void <B>setVerticalSpacing</B>(double spacing)</PRE>
<DL>
<DD>设置垂直网格线之间的间距(默认取磅值)。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>spacing</CODE> - 垂直网格线之间的间距,范围在0.05到1584磅之间 说明:set方法的参数默认取磅值,如果要用其他的度量单位(英寸、厘米、毫米、十二点活字), 可以用 application.util.Utilities.otherToPoint(double, int)方法将其他度量单位转换为磅值后再调用相应的设置方法。 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setVerticalSpacing(30); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当范围在0.05到1584磅之外时,抛出参数越界异常</DL>
</DD>
</DL>
<HR>
<A NAME="setVerticalStart(double)"><!-- --></A><H3>
setVerticalStart</H3>
<PRE>
public void <B>setVerticalStart</B>(double start)</PRE>
<DL>
<DD>设置垂直网格的起点(默认取磅值)。 说明:只有在不使用页边距状态下此方法才有效。
<P>
<DD><DL>
<DT><B>参数:</B><DD><CODE>start</CODE> - 垂直网格的起点,范围在0到1584磅之间 说明:set方法的参数默认取磅值,如果要用其他的度量单位(英寸、厘米、毫米、十二点活字), 可以用 application.util.Utilities.otherToPoint(double, int)方法将其他度量单位转换为磅值后再调用相应的设置方法。 <p> <b>例子:</b> <pre> Document doc = Application.getWorkbooks().getActiveWorkbook().getDocuments().getActiveDocument(); Section section = doc.getSection(0); WpPageSetup pageSetup = section.getPageSetup(); GridSettings settings = pageSetup.getGridSettings(); settings.setUsePageMarge(false); settings.setVerticalStart(10.0f); pageSetup.setGridSettings(settings); section.setPageSetup(pageSetup); </pre>
<DT><B>抛出:</B>
<DD><CODE><A HREF="../../../../../application/exceptions/MacroRunException.html" title="application.exceptions 中的类">MacroRunException</A></CODE> - 当使用页边距状态下,此方法抛出异常</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="跳过导航链接"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>概述</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>软件包</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>类</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>树</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>索引</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>帮助</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../application/workbooks/workbook/documents/document/FootNoteOptions.html" title="application.workbooks.workbook.documents.document 中的类"><B>上一个类</B></A>
<A HREF="../../../../../application/workbooks/workbook/documents/document/Index.html" title="application.workbooks.workbook.documents.document 中的类"><B>下一个类</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../index.html?application/workbooks/workbook/documents/document/GridSettings.html" target="_top"><B>框架</B></A>
<A HREF="GridSettings.html" target="_top"><B>无框架</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>所有类</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../allclasses-noframe.html"><B>所有类</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
摘要: 嵌套 | 字段 | 构造方法 | <A HREF="#method_summary">方法</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
详细信息: 字段 | 构造方法 | <A HREF="#method_detail">方法</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
版权所有 2001-2006 无锡永中科技有限公司
</BODY>
</HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -