a.exe c ();}
Compile and run the following command:
$ Cd ~ /Qt3hello$ Qmake-project$ Qmake$ Make$./Qt3hello
This is an example of QT4. The content is also from wiki.ubuntu.org.cn, but the above compilation command is wrong, wasting a lot of time for beginners like me. I corrected it.
First, create the folder qt4hello, and create the file main. cpp. The content is as follows:
# Include# Include
Int main (int argc, char * argv []){QApplication app (arg
In the process of learning QT, because I look at the information is QT3, and I installed QT is 4.6.0 version, so there will be some differences in the details. In this blog, I will keep statistics to update these subtle differences. Oh, but feel QT4 help document did really great ~
The current findings are as follows:
1, Setcaption function in 4, but can be replaced with setwindowstitle function, the same
Fedora complete with the series of stickers:
The first step FEDORA9 full configuration upgrade system scheme
The second step fedora9 full configuration Flsahplayer
The third step FEDORA9 fully configured QQ Chat tool
Fourth step fedora9 full configuration of listening mp3_ preferred XMMS
Fifth step fedora9 Full configuration MPlayer Configuration Guide
Sixth step fedora9 Full configuration of n graphics and 3D effects
Seventh step fedora9 Full configuration of vim configuration and C + + program
When installing Qt4 on Fedora, I used the root user at the beginning, which is slightly different from Ubuntu. Export mvqt-everywhere-opensource-src-4.6.2.tar.gz/tmp # cd/examples # cd
When installing Qt4 on Fedora, I used the root user at the beginning, which is slightly different from Ubuntu.# Music qt-everywhere-opensource-src-4.6.2.tar.gz/tmp# Cd/tmp# Gunzip qt-everywhere-opensource-src-4.6.2.tar.gz# Ta
QT4 is an open-source, very powerful cross-platform development framework. For example, if you want to develop a program with an interface rather than just a terminal, VB is the fastest in Windows, in Linux, non-QT4 does not belong to anyone. It has powerful functions and is very fast to learn. While QT4 comes with Fedora9, which saves us the trouble of re-instal
Although the local machine is installed with Gnome Ubuntu, you can also develop Qt programs. If you download and compile Qt4 normally, it will take a long time. Therefore, use apt-get to install Qt4. Run: $ sudoapt-getinstalllibqt4-devlibqt4-debuglibqt4-guilibqt4-sqlqt4-dev-toolsqt4-docqt4-designerqt4-qtconfi
Although the local machine is installed with Gnome Ubuntu, you can also develop Qt programs. If you
Make xconfig error:
* Unable to find the qt3 installation. Please make sure that* The qt3 development package is correctly installed and* Either install PKG-config or set the qtdir Environment* Variable to the correct location.*Make [1]: *** you can create the target "scripts/kconfig/. tmp_qtcheck" required by "scripts/kconfig/qconf. O" without rules ". Stop.Make: *** [xconfig] Error 2
First, make sure
Question: qt3 compilation error-Linux general technology-Linux programming and kernel information. The following is a detailed description. Helloworld. cpp: 1: 25: Error: qapplication. h: No such file or directory
Helloworld. cpp: 2: 20: Error: qwidget. h: No such file or directory
Helloworld. cpp: 3: 24: Error: qpushbutton. h: No such file or directory
Helloworld. cpp: In function 'int main (int, char **)':
Helloworld. cpp: 6: Error: 'qapplicatio
(TIFF, width, height, reinterpret_cast
When readrgbaimage (TIFF, width, height, reinterpret_cast
Compile and install oracle at the beginning. Just wait.
Qt-x11:
./Configure-qvfb
Make
CD tools/qvfb
Make
CD ../..
Make install
CP tools/qvfb */usr/local/trolltech/Qt-4.5.1/bin
Qt-embedded:
X86:
./Configure
Make
Make install
Arm:
./Configure-xplatform PWS/Linux-arm-G ++-arch arm
Make
Make install
The entire process takes more than five hours.
After the installation, the following interface appe
hours.
After the installation, the following interface appears, right, It installs the default path is:/usr/local/trolltech/Under the Qt-4.3.4
Configure the environment variables of qt4 as follows:
// Open the/etc/profile file and add the following statement at the end of the file:
Path =/usr/local/trolltech/Qt-4.3.4/bin: $ path
Qtdir =/usr/local/trolltech/Qt-4.3.4
Manpath = $ qtdir/MAN: $ manpath
LD_LIBRARY_PATH = $ qtdir/lib: $ LD_LIBRARY_PA
The reason why QT4 compilation fails is that the QT4 compilation method is actually very simple-Linux general technology-Linux programming and kernel information. The following is a detailed description. The problem that N multi-QT compilation on the Internet is not enough. After countless times of compilation, it is concluded that most of the reasons why QT compilation fails are due to a mistake in configu
Writing a program, especially developing a game application, is the most important thing to do is to see the running results. If you cannot see the instant effect of current screen flushing during debugging, you will feel very uncomfortable.
In fact, this article only mentions one sentence to solve this problem.
During Windows API development, you can
Hwnd createmediawex (DWORD dwexstyle,Maid,Lptstr lpwindowname,DWORD dwstyle,Int X,Int y,Int nwidth,Int nheight,Hwnd hwndparent,Hmenu,Hinstance,Lp
, as well as graphic effects, multimedia enhancement4. Qguiapplication and Qwindow were added for Qtquick, and if the traditional qwidgrets-based program is developed, the previous qapplication and Qmainwindow are still used5. The new Qtgui contains only a small number of GUI core content, the original Qt4 in the Qtgui contained in the majority of widgets, Itemview, Graphicsview related content has been moved to the Qtwidgets module, so in Qt5, If you
Qt4 under fedora9-general Linux technology-Linux programming and kernel information. The following is a detailed description. Just installed fedora9, which contains the built-in qt
Both qt3 and qt4
The built-in q4 seems to be of version 4.3.0.
However, when the qt4 designer is opened, only the window designer is ret
network programming, OpenGL support, and XML development. A wide range of uses depend on the platform independence of the QT class: except for a few, all classes are available on all operating systems, and the same classes have the same method and behavior.
Qt4 contains the following libraries:
Qtcore contains basic classes without GUI interfaces.Qtgui contains the GUI basic class.Qtnetwork contains Network classes.Qtopengl supports OpenGL.Qtsql co
I recently started to study qt4, bought a book "proficient in qt4 programming", installed qt4 and kdevelop on my Ubuntu, and wrote it manually in the command line.Code. There is no error during compilation and it can be run successfully. However, after a qt4 project is created in kdevelop, compilation fails. the follow
SQL connection plug-in, note that the LIBPQ and Libmysql-related library files are copied to the folder where the executable file is located, not to the folder where the plugins is located, otherwise the connection may fail, although it can be enumerated to the driver. If you refer to the OCI plug-in, be careful not to copy Oci.dll to the publishing folder, which in some cases causes the connection to fail. Instead, use the Oracle connection instance on the machine path system for publishing pu
QT4 Chinese garbled characters-general Linux technology-Linux programming and kernel information. The following is a detailed description. For beginners of Linux, go to advanced QT programming. However, the first Demo program encountered a Chinese Garbled text, a great sweat!
Environment:
1. RedHat AS5
2. QT4.4.0
3. LANG = "zh_CN.GB18030"
Program:
...
QTextCodec: setCodecForTr (QTextCodec: codecForName ("gb18030 "));
...
Label. setText (QObject: tr (
Recently, I encountered a project that requires QT for interface development. I remember the last time I used QT, it was two years ago. At that time, qt3 was quite comfortable to use. But now I have installed qt4 to know that QT has changed a lot. The usage of UIC and qmake has changed. So it took an afternoon to adapt to the new environment.
First, read the following blogs. Basically, there is a general i
1. First install QT4 and use QT Creator for development demonstration (1) Enter in Terminal:sudo apt-get install qt4-dev-tools qt4-doc qt4-qtconfig Qt4-demos Qt4-designerwhichThe qt4-de
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.