当前位置:网站首页>泰山OFFICE技术讲座:由行的布局高度,谈绘制高度的高度溢出、高度缩水(全网首发)
泰山OFFICE技术讲座:由行的布局高度,谈绘制高度的高度溢出、高度缩水(全网首发)
2022-07-05 18:36:00 【柳鲲鹏】
在之前的博文中,吾提出除,行视图除了字体高度,还有一个布局高度。现在又要提出绘制高度的概念。什么叫绘制高度?比如说,布局高度是18.1,绘制时的高度一般是18,也有可能不是。这个时候就需要绘制高度。
绘制高度是怎么来的?绘制高度是因为像素是整数导致的。比如说行高18.1,从96开始绘制,5行之后的y坐标就是96+90.5。绘制时候显然不能是浮点像素,所以要四舍五入,就是96+91。如果考虑高度呢?情形就更加复杂了。根据尾数的不同,实际上有四种情形:
- 绘制高度,正常情形。y小数小于0.5,y+height小数小于0.5
- 绘制高度,正常情形。y小数大于0.5,y+height小数大于0.5
- 绘制高度,高度缩水。y小数大于0.5,y+height小数小于0.5
此时绘制高度缩水1个像素,由18变成17。
- 绘制高度,高度溢出。y小数小于0.5,y+height小数大于0.5
此时绘制高度溢出1个像素,由18变成19。
边栏推荐
- The monthly list of Tencent cloud developer community videos was released in May 2022
- Rse2020/ cloud detection: accurate cloud detection of high-resolution remote sensing images based on weak supervision and deep learning
- The 11th China cloud computing standards and Applications Conference | cloud computing national standards and white paper series release, and Huayun data fully participated in the preparation
- Is it complicated to open an account? Is online account opening safe?
- 进程间通信(IPC):共享内存
- 关于服装ERP,你想知道的都在这里了
- Low code practice of xtransfer, a cross-border payment platform: how to integrate with other medium-sized platforms is the core
- Personal understanding of convolutional neural network
- How to write good code defensive programming
- ROS安装报错 sudo: rosdep:找不到命令
猜你喜欢
Oracle日期格式转换 to_date,to_char,to_timetamp 相互转换
Vulnhub's darkhole_ two
AI Open2022|基于异质信息网络的推荐系统综述:概念,方法,应用与资源
MYSQL中 find_in_set() 函数用法详解
技术分享 | 常见接口协议解析
Memory leak of viewpager + recyclerview
A2L file parsing based on CAN bus (3)
Pytorch yolov5 training custom data
【HCIA-cloud】【1】云计算的定义、什么是云计算、云计算的架构与技术说明、华为云计算产品、华为内存DDR配置工具说明
Case sharing | integrated construction of data operation and maintenance in the financial industry
随机推荐
LeetCode 6111. Spiral matrix IV
Emqx 5.0 officially released: a single cluster supports 100million mqtt connections
自动化测试的好处
XML基础知识概念
尚硅谷尚优选项目教程发布
@Extension、@SPI注解原理
Deep copy and shallow copy [interview question 3]
sample_ What is the relationship between rate, sample and duration
Tianyi cloud understands enterprise level data security in this way
The era of Web3.0 is coming. See how Tianyi cloud storage resources revitalize the system to enable new infrastructure (Part 2)
MySQL优化六个点的总结
Icml2022 | partial and asymmetric comparative learning of out of distribution detection in long tail recognition
技术分享 | 常见接口协议解析
C language makes it easy to add, delete, modify and check the linked list "suggested collection"
Find in MySQL_ in_ Detailed explanation of set() function usage
Interprocess communication (IPC): shared memory
Simple query cost estimation
【HCIA-cloud】【1】云计算的定义、什么是云计算、云计算的架构与技术说明、华为云计算产品、华为内存DDR配置工具说明
视频融合云平台EasyCVR增加多级分组,可灵活管理接入设备
EasyCVR授权到期页面无法登录,该如何解决?