Редактирование: Qt:Документация 4.3.2/uic

Материал из Wiki.crossplatform.ru

Перейти к: навигация, поиск
Внимание: Вы не представились системе. Ваш IP-адрес будет записан в историю изменений этой страницы.
Правка может быть отменена. Пожалуйста, просмотрите сравнение версий, чтобы убедиться, что это именно те изменения, которые вас интересуют, и нажмите «Записать страницу», чтобы изменения вступили в силу.
Текущая версия Ваш текст
Строка 2: Строка 2:
=User Interface Compiler (uic)<br />=
=User Interface Compiler (uic)<br />=
-
<div id="uic"></div>
 
This page documents the ''User Interface Compiler'' for the Qt GUI toolkit. The <tt>uic</tt> reads an XML format user interface definition (<tt>.ui</tt>) file as generated by [[Qt:Документация 4.3.2/designer-manual | Qt Designer]] and creates a corresponding C++ header file.
This page documents the ''User Interface Compiler'' for the Qt GUI toolkit. The <tt>uic</tt> reads an XML format user interface definition (<tt>.ui</tt>) file as generated by [[Qt:Документация 4.3.2/designer-manual | Qt Designer]] and creates a corresponding C++ header file.
Usage:
Usage:
-
<source lang="cpp-qt"> uic [options] <uifile></source> <div id="options"></div>
+
<source lang="cpp-qt"> uic [options] &lt;uifile&gt;</source>  
-
 
+
==Options==
==Options==
The following table lists the command-line options recognized by <tt>uic</tt>.
The following table lists the command-line options recognized by <tt>uic</tt>.
 +
{|  align="center" cellpadding="2" cellspacing="1" border="0"
{|  align="center" cellpadding="2" cellspacing="1" border="0"
Строка 16: Строка 15:
!Description
!Description
|- valign="top" class="odd" |  
|- valign="top" class="odd" |  
-
|<tt>-o <file></tt>
+
|<tt>-o &lt;file&gt;</tt>
-
|Write output to <tt><file></tt> instead of to standard output.
+
|Write output to <tt>&lt;file&gt;</tt> instead of to standard output.
|- valign="top" class="even" |  
|- valign="top" class="even" |  
-
|<tt>-tr <func></tt>
+
|<tt>-tr &lt;func&gt;</tt>
-
|Use <tt><func></tt> for translating strings instead of <tt>tr()</tt>.
+
|Use <tt>&lt;func&gt;</tt> for translating strings instead of <tt>tr()</tt>.
|- valign="top" class="odd" |  
|- valign="top" class="odd" |  
|<tt>-p</tt>
|<tt>-p</tt>
Строка 31: Строка 30:
|Display <tt>uic</tt>'s version number.
|Display <tt>uic</tt>'s version number.
|}
|}
-
<div id="examples"></div>
 
-
==Examples==
 
 +
==Examples==
If you use <tt>qmake</tt>, <tt>uic</tt> will be invoked automatically for header files.
If you use <tt>qmake</tt>, <tt>uic</tt> will be invoked automatically for header files.
Here are useful makefile rules if you only use GNU make:
Here are useful makefile rules if you only use GNU make:
<source lang="cpp-qt"> ui_%.h: %.ui
<source lang="cpp-qt"> ui_%.h: %.ui
-
         uic $< -o $@</source>  
+
         uic $&lt; -o $@</source>  
If you want to write portably, you can use individual rules of the following form:
If you want to write portably, you can use individual rules of the following form:
<source lang="cpp-qt"> ui_foo.h: foo.ui
<source lang="cpp-qt"> ui_foo.h: foo.ui
-
         uic $< -o $@</source>  
+
         uic $&lt; -o $@</source>  
You must also remember to add <tt>ui_foo.h</tt> to your <tt>HEADERS</tt> (substitute your favorite name).
You must also remember to add <tt>ui_foo.h</tt> to your <tt>HEADERS</tt> (substitute your favorite name).
{{Qt4.3.2_footer}}
{{Qt4.3.2_footer}}

Пожалуйста, обратите внимание, что все ваши добавления могут быть отредактированы или удалены другими участниками. Если вы не хотите, чтобы кто-либо изменял ваши тексты, не помещайте их сюда.
Вы также подтверждаете, что являетесь автором вносимых дополнений, или скопировали их из источника, допускающего свободное распространение и изменение своего содержимого (см. Wiki.crossplatform.ru:Авторское право). НЕ РАЗМЕЩАЙТЕ БЕЗ РАЗРЕШЕНИЯ ОХРАНЯЕМЫЕ АВТОРСКИМ ПРАВОМ МАТЕРИАЛЫ!


Шаблоны, использованные на текущей версии страницы: