当前位置:网站首页>Use some examples of qte5
Use some examples of qte5
2022-06-29 05:13:00 【fqbqrr】
//QtE5- Single form
Import mark . mark io;
Import qte56; //QtE5 Graphics library
Import The core . Runtime ; // Processing input parameters
//dmd p2.d qte56.d -release -mcpu=native -m64
often Red string =" background : Pink ";
//____________________________________
// Start applying for ...
whole Lord ( strand [] Parameters ){
extremely f debugging = really ; // Load with debug information QtE56
// Error during download , Press code 1 sign out
Such as (1== load qt( Dynamic library .qte6 Components ,f debugging )) in 1;
// Submit master Q application
q application application = new q application (& Runtime .c Actual parameters . Number of parameters , Runtime .c Actual parameters . Parameter value ,1);
// Program code
q Components Components = new q Components ( Invalid );
Components . Set window title ("===[ come from QtE5 Greetings from !]==="). Set style table ( Red string ). Show ();
//----
in application . perform ();
}
//(QtE5-QImage The image in the window )Image- open , Rescale
Import mark . mark io;
Import qte56; //QtE5 Graphics library
Import The core . Runtime ; // Processing input parameters
//dmd t1.d qte56.d -release -mcpu=native -m64
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//CView Image rendering window
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Outside (C){
empty When drawing components (c Depending on the * The British , empty *ev, empty *q draw ){(* The British ). Running painting (ev,q draw );};
}
//____________________________________
class c Depending on the :q Components {
q Images im;
q The needle The pointer ;
often w window =800;
Ben (){
super ( Invalid );
// Request image file view
q File dialog File dialog = new q File dialog ('+', Invalid );
strand command = File dialog . Take the file name string (" Specify the drawing file ...","","*.jpg*.png*.ppt*.gif");
Such as ( command !=""){
im= new q Images ();im. load ( command );
adjustment (w window , transformation ( whole )( transformation ( real )im. Height /( transformation ( real )im. Width / transformation ( real )w window )));
Writing lines (" Width =",im. Width ," Height =",im. Height );
Painting event (& When drawing components , a copy ());
Set window title ( command );
} different {
Set window title ("=== no choice ===");
}
}
//___
// Redraw yourself
empty Running painting ( empty *ev, empty *q draw ){//-> Redraw area
q Painter qp= new q Painter ('+',q draw );
// Zoom to fit the widget
q Moment Number = new q Moment ();
qp. Draw an image ( Moment content ( Number ),im);
// Scale according to the width of the main window
adjustment ( Width , transformation ( whole )( transformation ( real )im. Height /( transformation ( real )im. Width / transformation ( real ) Width )));
Number . eliminate ();
qp. tail ();
}
}
empty Lord ( strand [] Parameters ){
Such as (1== load qt( Dynamic library .qte6 Components | Dynamic library .qte6 The core , false )) in ;
q application application = new q application (& Runtime .c Actual parameters . Number of parameters , Runtime .c Actual parameters . Parameter value ,1);
c Depending on the Components = new c Depending on the (); Components . Save this (& Components ); Components . Show ();
application . perform ();
}
//(QtE5-QLabel greetings )QLabel That's one example .
Import qte56;//QtE5 Graphics library
Import The core . Runtime ;// Processing input parameters
//dmd t1.d qte56.d -release -mcpu=native -m64
empty Lord ( strand [] Parameters ){
strand s="
<p><font size='34' color='red'>QtE5</font>
<font size='34' color='blue'><i>Qt-5 Small package </i></font></p>";
Such as (1== load qt( Dynamic library .qte6 Components , false ))
in ;
q application application = new q application (& Runtime .c Actual parameters . Number of parameters , Runtime .c Actual parameters . Parameter value ,1);
q label lb= new q label ( Invalid );
lb. Set text (s). Show ();
application . perform ();
}
- 1.
- 2.
- 3.
- 4.
- 5.
- 6.
- 7.
- 8.
- 9.
- 10.
- 11.
- 12.
- 13.
- 14.
- 15.
- 16.
- 17.
- 18.
- 19.
- 20.
- 21.
- 22.
- 23.
- 24.
- 25.
- 26.
- 27.
- 28.
- 29.
- 30.
- 31.
- 32.
- 33.
- 34.
- 35.
- 36.
- 37.
- 38.
- 39.
- 40.
- 41.
- 42.
- 43.
- 44.
- 45.
- 46.
- 47.
- 48.
- 49.
- 50.
- 51.
- 52.
- 53.
- 54.
- 55.
- 56.
- 57.
- 58.
- 59.
- 60.
- 61.
- 62.
- 63.
- 64.
- 65.
- 66.
- 67.
- 68.
- 69.
- 70.
- 71.
- 72.
- 73.
- 74.
- 75.
- 76.
- 77.
- 78.
- 79.
- 80.
- 81.
- 82.
- 83.
- 84.
- 85.
- 86.
- 87.
- 88.
- 89.
- 90.
- 91.
- 92.
- 93.
- 94.
- 95.
- 96.
- 97.
- 98.
边栏推荐
- JVM memory tuning method
- Accelerate the global cloud native layout, kyligence intelligent data cloud officially supports Google cloud
- Experience sharing of system analysts in preparing for exams: phased and focused
- Sailing with karmada: multi cluster management of massive nodes
- [structural mechanics] the reason why the influence line under joint load is different from that under direct load
- 2022-2028 global and Chinese industrial digital electronic blasting detonator Market Status and future development trend
- [Verilog quick start of Niuke network question brushing series] ~ asynchronous reset Series T trigger
- 安捷伦数字万用表软件NS-Multimeter,实时数据采集数据自动保存
- 5000+ 字解读 | 产品经理:如何做好元器件选型?
- 20年秦皇島D - Exam Results(二分+思維,附易錯數據)
猜你喜欢

5000+ 字解读 | 产品经理:如何做好元器件选型?

be based on. NETCORE development blog project starblog - (13) add friendship link function

网络设备设置/取消console口登陆单独密码

Mysql 中的 mvcc原理
![[high concurrency] deeply analyze the callable interface](/img/42/43d1f0b894f2632f2c7f1bfe970708.jpg)
[high concurrency] deeply analyze the callable interface

Service grid ASM year end summary: how do end users use the service grid?

Facade pattern

On February 15, the market hot money operation and the dragon and tiger list

基于.NetCore开发博客项目 StarBlog - (13) 加入友情链接功能

What are the ways to simulate and burn programs? (including common tools and usage)
随机推荐
5000+ 字解读 | 产品经理:如何做好元器件选型?
5000+ word interpretation | Product Manager: how to do a good job in component selection?
开启生态新姿势 | 使用 WordPress 远程附件存储到 COS
Force deduction solution summary 324- swing sequencing II
[structural mechanics] the reason why the influence line under joint load is different from that under direct load
Sailing with karmada: multi cluster management of massive nodes
【代码随想录-动态规划】最长公共子序列
Research Report on the overall scale, major manufacturers, major regions, product and application segmentation of GSM and GPRS modules in the global market in 2022
《软件体系结构》期末复习总结
[IOT] description of renaming the official account "Jianyi commerce" to "product renweipeng"
How to change the password of mysql8 created by docker
Kubernetes backup disaster recovery service product experience tutorial
20年秦皇島D - Exam Results(二分+思維,附易錯數據)
Cipher
Research Report on the overall scale, major manufacturers, major regions, products and applications of magnetron sputtering coaters in the global market in 2022
Use VS to create a static link library Lib and use
How to display all MySQL databases
20 years Qinhuangdao D - exam results (dichotomy + thinking, with error prone data)
Template method pattern
嵌入式RTOS