当前位置:网站首页>GTK interface programming (I): Environment Construction
GTK interface programming (I): Environment Construction
2022-06-30 02:51:00 【EEer!】
List of articles
One 、 Environment building
1. install GNU Compile link tool
sudo apt-get install build-essential
2. install gtk3
sudo apt-get install libgtk-3-dev
3. install pkg-config For automatic discovery gtk The location of the header file
sudo apt-get install pkg-config
After installation , You can use the following command to verify that the installation was successful , And look at GTK+3.0 The path of all the included header files and libraries :
pkg-config --cflags --libs gtk+-3.0
The verification results :
4.GUI verification
Use the official example to test whether it can run
main.c The sample code is as follows :
#include <gtk/gtk.h>
int main( int argc, char *argv[])
{
GtkWidget *window;
gtk_init(&argc, &argv);
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
gtk_widget_show(window);
gtk_main();
return 0;
}
The compilation instructions are as follows :
sudo gcc main.c -o main `pkg-config --cflags --libs gtk+-3.0`
function :
./main
The verification results :
Two 、GTK Official documents
https://docs.gtk.org/gtk3/
边栏推荐
- unity的text首列有标点符号咋办
- Intel hex, Motorola S-Record format detailed analysis
- C语言 pivot_root的Invalid argument错误解决方案
- What is the difference between a layer 3 switch and a layer 2 switch
- Multi card server usage
- C language pivot_ Invalid argument error resolution for root
- Jvxetable增加自定义按钮
- Three solutions to forced hibernation of corporate computers
- How to switch ipykernel to a different CONDA virtual environment in jupyterlab?
- 怎么利用Redis实现点赞功能
猜你喜欢

How to prevent phishing emails? S/mime mail certificate

Unity3d ugui force refresh of layout components

Ffmpeg source code

Several key points recorded after reviewing redis design and Implementation

FDA ESG规定:必须使用数字证书保证通信安全

IBM WebSphere channel connectivity setup and testing

How to modify and add fields when MySQL table data is large

Idea remote debugging remote JVM debug
![[on] [DSTG] dynamic spatiotemporalgraph revolutionary neural networks for traffic data impact](/img/c3/f9d6399c931a006ca295bb1e3ac427.png)
[on] [DSTG] dynamic spatiotemporalgraph revolutionary neural networks for traffic data impact

在php中字符串的概念是什么
随机推荐
Raki's notes on reading paper: discontinuous named entity recognition as maximum clique discovery
微信小程序页面跳转以及参数传递
最小栈详解
What is an X.509 certificate? 10. 509 certificate working principle and application?
Lua 基础知识
Study diary: February 15, 2022
Detailed explanation of minimum stack
Global and Chinese markets for wireless security in LTE networks 2022-2028: Research Report on technology, participants, trends, market size and share
Entering Jiangsu writers and poets carmine Jasmine World Book Day
Creating exquisite skills in maker Education
How can redis+aop customize annotations to achieve flow restriction
Enlightenment from the revocation of Russian digital certificate by mainstream CA: upgrade the SSL certificate of state secret algorithm to help China's network security to be autonomous and controlla
Welfare lottery | what are the highlights of open source enterprise monitoring zabbix6.0
[NPM] solve the problem of error reporting when installing typeorm with NPM
How to use redis to realize the like function
FDA ESG规定:必须使用数字证书保证通信安全
Redis+AOP怎么自定义注解实现限流
Jupyter notebook显示k线图集合
Global and Chinese market of relay lens 2022-2028: Research Report on technology, participants, trends, market size and share
CMake教程系列-01-最小配置示例