EdChange.sgm 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. <!-- $XConsortium: EdChange.sgm /main/5 1996/08/30 12:57:35 rws $ -->
  2. <!-- (c) Copyright 1995 Digital Equipment Corporation. -->
  3. <!-- (c) Copyright 1995 Hewlett-Packard Company. -->
  4. <!-- (c) Copyright 1995 International Business Machines Corp. -->
  5. <!-- (c) Copyright 1995 Sun Microsystems, Inc. -->
  6. <!-- (c) Copyright 1995 Novell, Inc. -->
  7. <!-- (c) Copyright 1995 FUJITSU LIMITED. -->
  8. <!-- (c) Copyright 1995 Hitachi. -->
  9. <![ %CDE.C.CDE; [<RefEntry Id="CDEMX.XCSA.MAN16.rsml.1">]]>
  10. <![ %CDE.C.XO; [<RefEntry Id="XCSA.MAN16.rsml.1">]]>
  11. <RefMeta>
  12. <RefEntryTitle>DtEditorChange</RefEntryTitle>
  13. <ManVolNum>library call</ManVolNum>
  14. </RefMeta>
  15. <RefNameDiv>
  16. <RefName><Function>DtEditorChange</Function></RefName>
  17. <RefPurpose>change one or all occurrences of a string in a DtEditor widget
  18. </RefPurpose>
  19. </RefNameDiv>
  20. <!-- CDE Common Source Format, Version 1.0.0-->
  21. <!-- *************************************************************************-->
  22. <!-- ** (c) Copyright 1993, 1994, 1995 Hewlett-Packard Company-->
  23. <!-- ** (c) Copyright 1993, 1994, 1995 International Business Machines Corp.-->
  24. <!-- ** (c) Copyright 1993, 1994, 1995 Sun Microsystems, Inc.-->
  25. <!-- ** (c) Copyright 1993, 1994, 1995 Novell, Inc.-->
  26. <!-- *************************************************************************-->
  27. <RefSynopsisDiv>
  28. <FuncSynopsis Remap="ANSI">
  29. <FuncSynopsisInfo>#include &lt;Dt/Editor.h>
  30. </FuncSynopsisInfo>
  31. <FuncDef>Boolean <Function>DtEditorChange</Function></FuncDef>
  32. <ParamDef>Widget <Parameter>widget</Parameter></ParamDef>
  33. <ParamDef>DtEditorChangeValues *<Parameter>findChangeStrings</Parameter></ParamDef>
  34. <ParamDef>unsigned int <Parameter>instanceToChange</Parameter></ParamDef>
  35. </FuncSynopsis>
  36. </RefSynopsisDiv>
  37. <RefSect1>
  38. <Title>DESCRIPTION</Title>
  39. <Para>The
  40. <Function>DtEditorChange</Function> function replaces the next occurrence of a string, all occurrences of
  41. the string, or the currently selected text in a DtEditor widget with a
  42. replacement string.
  43. The string to search for and the value to
  44. change it to can be the last values entered in the Find/Change
  45. dialog (see
  46. &cdeman.DtEditorInvokeFindChangeDialog;) or passed as arguments to
  47. <Function>DtEditorChange</Function>.</Para>
  48. <Para>The search begins at the insertion cursor.
  49. If the string is not found by the time the end of the document is reached,
  50. the search continues at the beginning of the document,
  51. stopping at the character before the insertion cursor.
  52. </Para>
  53. <Para>The
  54. <Symbol Role="Variable">widget</Symbol> argument specifies the DtEditor widget ID.
  55. </Para>
  56. <Para>The
  57. <Emphasis>findChangeStrings</Emphasis> argument specifies the string to change and the replacement value.
  58. If
  59. <Emphasis>findChangeStrings</Emphasis> is
  60. <SystemItem Class="Constant">NULL</SystemItem>, <Function>DtEditorChange</Function> uses the last string specified in the Find and Change To fields
  61. of the Find/Change dialog.
  62. If the
  63. <Emphasis>instanceToChange</Emphasis> argument is
  64. <SystemItem Class="Constant">DtEDITOR_CURRENT_SELECTION</SystemItem>, the Find field of
  65. <StructName Role="typedef">DtEditorChangeValues</StructName> is ignored.
  66. </Para>
  67. <Para>If the
  68. <Emphasis>instanceToChange</Emphasis> argument
  69. is set to
  70. <SystemItem Class="Constant">DtEDITOR_NEXT_OCCURRENCE</SystemItem>, <Function>DtEditorChange</Function> replaces the next occurrence (relative to the
  71. insertion cursor) of the find string.
  72. If this argument is set to
  73. <SystemItem Class="Constant">DtEDITOR_ALL_OCCURRENCES</SystemItem>, all instances of the find string are changed.
  74. If this argument ia set to
  75. <SystemItem Class="Constant">DtEDITOR_CURRENT_SELECTION</SystemItem>, the Find field of
  76. <StructName Role="typedef">DtEditorChangeValues</StructName>, is ignored and the currently selected text is replaced.
  77. <![ %CDE.C.CDE; [</Para>
  78. <Para>For a complete definition of the DtEditor widget
  79. and its associated resources, see
  80. &cdeman.DtEditor;. ]]></Para>
  81. <Para>For a complete definition of
  82. <StructName Role="typedef">DtEditorChangeValues</StructName>, see
  83. &cdeman.Dt.Editor.h;.</Para>
  84. </RefSect1>
  85. <RefSect1>
  86. <Title>RETURN VALUE</Title>
  87. <Para>Upon successful completion, the
  88. <Function>DtEditorChange</Function> function returns
  89. True
  90. if the substitution occurred;
  91. otherwise, it returns
  92. False.
  93. </Para>
  94. </RefSect1>
  95. <RefSect1>
  96. <Title>SEE ALSO</Title>
  97. <Para>&cdeman.Dt.Editor.h;, &cdeman.DtEditor;, &cdeman.DtEditorFind;, &cdeman.DtEditorInvokeFindChangeDialog;.</Para>
  98. </RefSect1>
  99. </RefEntry>
  100. <!--fickle 1.12 mancsf-to-docbook 1.2 08/07/95 23:40:24-->