1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00
cdt/doc/org.eclipse.cdt.doc.user/tasks/cdt_t_contentassist.htm
2003-12-19 20:47:29 +00:00

83 lines
No EOL
3.3 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html lang="en">
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Using Content Assist</title>
<link rel="stylesheet" type="text/css" href="../help.css">
</head>
<body>
<h1>Using Content Assist</h1>
<p>Use Content Assist to insert C/C++ elements of your project or referenced project(s),
and code templates into your code. You can insert a code template into your source code rather than retyping
commonly-used snippets of code.</p>
<p>To insert a code template or element:</p>
<ol>
<li>In the C/C++ editor, type at least the first letter of a code template or
element.</li>
<li>Click <b>Edit &gt; Content Assist</b>.<br>
A list displays the code templates
<img border="0" src="../images/template_obj.gif" width="16" height="16"> followed by the elements, in
alphabetical order, that start with the letter combination
you typed.</li>
<li>Do one of the following:
<ul>
<li>Continue typing. The list shortens. When there is only one item in the
list, it is automatically inserted.</li>
<li>Double-click an item in the list to insert it into your code. </li>
<li>Press <b>Esc</b> to close the Content Assist Window.</li>
</ul>
</li>
</ol>
<p>To set Content Assist preferences:</p>
<ol>
<li>Click <b>Window &gt; Preferences</b>.</li>
<li>Expand <b>C/C++</b>, and click<b>C/C++ Editor</b>.</li>
<li>Click the <b>Content Assist</b> tab.</li>
<li>Do the following:
<ul>
<li>To insert an element when you open Content Assist and it is the only
item
in the list, select the <b>Insert single proposals automatically</b> check
box.</li>
<li>To automatically open Content Assist when you type the first letter of an
element for which there is a match, select the <b>Enable auto activation</b>.
</li>
<li>To turn on Content Assist after a given number of seconds, type a value
in the <b>Auto activation delay</b> box.</li>
<li>To specify a character that, if typed in the C/C++ editor, causes code
assist to be invoked immediately&nbsp; before the delay times out, type a
trigger in the <b>Auto activation triggers for C:</b> box.</li>
<li>To change the background color of the Content Assist dialog box, click
the color palette button.</li>
</ul>
</li>
<li>Click <b>OK</b>.</li>
</ol>
<p><img border="0" src="../images/ngconcepts.gif" ALT="Related concepts" width="143" height="21">
<br>
<a href="../concepts/cdt_c_content_assist.htm">Content Assist</a></p>
<p><img border="0" src="../images/ngtasks.gif" ALT="Related tasks" width="143" height="21">
<br>
<a href="cdt_t_add_codetemp.htm">Creating and editing code templates</a><br>
<a href="cdt_t_imp_code_temp.htm">Importing and exporting code templates</a></p>
<p><img border="0" src="../images/ngref.gif" ALT="Related reference" width="143" height="21">
<br>
<a href="../reference/cdt_u_c_editor_con_assist.htm">Content Assist page, Preferences window</a><br>
<a href="../reference/cdt_u_code_temp.htm">Code Templates page</a></p>
<p>
<img src="../images/ng03_04.gif" ALT="IBM Copyright Statement" BORDER=0 width="324" height="14">
</body>
</html>