Welcome to Archie Meng's Blog

Do you pine for the days when men were men and wrote their own device drivers?

announcement of the posting of Linux version 0.02

记一次实现deepin-terminal"自动隐藏标题栏的沉浸式全屏"的过程

category: deepin-terminal deepin C++

archiemeng | March 26, 2023, 12:46 p.m. | viewed: 97

起因

https://bbs.deepin.org/zh/post/219784 帖子的七楼说希望全屏隐藏顶栏,然后就在哪里看到有人说旧版deepin-terminal的行为就是这样的.一试,果然.看样子必须要做了.

计划实现方式

当时猜想有两种实现方法:

  • 改windowFlags,让窗口标题栏隐藏.
  • 找到Titlebar的对象,然后设置隐藏.
  • 为了说明,以下代码均使用 commit 8eea62a986f8d80562c3449985919980f6828eed 的版本

    失败的尝试

    首先,因为刚接触这个项目,对其具体代码了解也不是很深,想先用改windowFlags的方式去做.

    搜索代码全文中的fullscreen:

    ......

    Read More →