当前位置:网站首页>Zero basic learning canoe panel (12) -- progress bar
Zero basic learning canoe panel (12) -- progress bar
2022-07-25 12:50:00 【Ant soldier】
- I am a Ant soldier , Focus on the field of on-board diagnosis , Especially good at CANoe Tool use
- Looking for organizations , Answer questions and solve doubts , Fishing and chatting , Blog source code , Click to add 【 Love each other and family 】
- Zero base learning CANoe Panel Summary of design catalogue , Click the jump
Preface
Progress bar (
Progress Bar) strip , whatever UI Design tools are available , Let me write a simpleBrush serviceTo demonstrate the use of the progress barDemonstrate hardware and software environment
Windows11 x64;CANoe 11 SP2 x64
Catalog

Progress bar (Progress Bar)
1️⃣ Next I pull three controls Button ,Input/Output box ,Progress Bar To simulate the download service
Button: Start the downloadInput/Output box: Download progress description , Property to set the transparent amount , So I can't see the screenshotProgress Bar: Download progress percentage

2️⃣ Because the purpose is to demonstrate the use of the progress bar , So here is a simple simulation of the download process , Here we define a timer , Add to 100, Simulate the progress of brushing .
/*@!Encoding:936*/
variables
{
msTimer timer_demo;
char tempText[0x500];
int step_counter;
}
on timer timer_demo
{
step_counter = step_counter +1 ;
snprintf(tempText,elCount(tempText),"Downloading %.2f%%......",(double)step_counter);
sysSetVariableString (sysvar::Panel::ProgressBar_Log,tempText);
sysSetVariableFloat(sysvar::Panel::ProgressBar_Self,(double)step_counter);
if (step_counter < 100)
setTimer(timer_demo,100);
}
on sysvar Panel::ProgressBar_Start
{
if(@this)
{
snprintf(tempText,elCount(tempText),"Satrt Downloading......");
sysSetVariableString (sysvar::Panel::ProgressBar_Log,tempText);
StartDownload();
}
}
void StartDownload()
{
step_counter = 0;
setTimer(timer_demo,1000);
}
/* When the above code Editor Control demo code */
3️⃣ Run rise CANoe, The test process is as follows :

Property settings
The above example , I didn't set any properties , Completely default
1️⃣ Hide the text of the progress bar itself
- Most of us don't use it , I will use the previous example , Therefore, it is the first choice to hide it

2️⃣ Progress bar direction
- You can choose vertical or horizontal progress bar

3️⃣ Text decimal places
- If you don't set hidden text , Then the setting is meaningful .

How to make the progress bar design colorful
1️⃣ Look at the picture below , Default Style Attribute matters Windows Style Of , The color of the progress bar and the background color are gray , Not set , So we need to design a good-looking progress bar , We need to change Style attribute

2️⃣ Now I choose Classic Style With Frame Pattern , And set the background color of the progress bar to light yellow , The progress bar is set to positive yellow , Here's the picture

3️⃣ Run the renderings

4️⃣ Odometer style (Level Meter Style)( Optional learn )
- Only
StyleAttribute select itsLevel Meter Style,Level Meter settingThe properties inside can be set , The progress bar is preceded by a vertical line with optional colors .


summary


- Have the most simple life , The furthest dream , Even if it's freezing tomorrow , Lu Yao's horse died !
- If this blog is helpful to you , please “ give the thumbs-up ” “ Comment on ”“ Collection ” One key, three links Oh ! It's not easy to code words , Everyone's support is my driving force to stick to it .
边栏推荐
- Script set random user_ agent
- 2022.07.24(LC_6125_相等行列对)
- Clickhouse notes 03-- grafana accesses Clickhouse
- 卷积核越大性能越强?一文解读RepLKNet模型
- 【AI4Code】《CoSQA: 20,000+ Web Queries for Code Search and Question Answering》 ACL 2021
- shell基础知识(退出控制、输入输出等)
- 【AI4Code】《Contrastive Code Representation Learning》 (EMNLP 2021)
- Microsoft azure and Analysys jointly released the report "Enterprise Cloud native platform driven digital transformation"
- Kyligence was selected into Gartner 2022 data management technology maturity curve report
- 2022河南萌新联赛第(三)场:河南大学 I - 旅行
猜你喜欢
Software testing interview question: Please list the testing methods of several items?

基于JEECG制作一个通用的级联字典选择控件-DictCascadeUniversal

【Rust】引用和借用,字符串切片 (slice) 类型 (&str)——Rust语言基础12

LeetCode 0133. 克隆图

【AI4Code】《Contrastive Code Representation Learning》 (EMNLP 2021)
![[advanced C language] dynamic memory management](/img/b7/6586b35500eb8f39a3ea8c125fb572.png)
[advanced C language] dynamic memory management

Visualize the training process using tensorboard

跌荡的人生

Selenium use -- installation and testing

485通讯( 详解 )
随机推荐
2022.07.24 (lc_6125_equal row and column pairs)
【AI4Code】《CodeBERT: A Pre-Trained Model for Programming and Natural Languages》 EMNLP 2020
2022 年中回顾 | 大模型技术最新进展 澜舟科技
软件测试流程包括哪些内容?测试方法有哪些?
我在源头SQLServer里面登记绝对删除的数据,传到MaxComputer,在数据清洗的时候写绝对
【AI4Code】《CoSQA: 20,000+ Web Queries for Code Search and Question Answering》 ACL 2021
【10】 Scale bar addition and adjustment
Does MySQL have flush privileges
“蔚来杯“2022牛客暑期多校训练营2 补题题解(G、J、K、L)
Azure Devops (XIV) use azure's private nuget warehouse
ORAN专题系列-21:主要的玩家(设备商)以及他们各自的态度、擅长领域
A turbulent life
【2】 Grid data display stretch ribbon (take DEM data as an example)
Numpy first acquaintance
perf 性能调试
Detailed explanation of switch link aggregation [Huawei ENSP]
请问一下,使用数据集成从postgreSQL导数据到Mysql数据库,有部分数据的字段中出现emoj
conda常用命令:安装,更新,创建,激活,关闭,查看,卸载,删除,清理,重命名,换源,问题
迁移PaloAlto HA高可用防火墙到Panorama
Selenium uses -- XPath and analog input and analog click collaboration
