This forum has been archived. All content is frozen. Please use KDE Discuss instead.

KDE is not setting frame buffer size to 0,0 when minimzed?

Tags: None
(comma "," separated)
Registered Member
Let me preface this by saying that I am new to this forum and I am sorry if this is the wrong place for this post. I was going to post it in the community area but I thought that it was pretty technical and I should probably post it here instead so it got more coverage.

I am currently working on a Vulkan based 3D rendering program using C++, the details of the project are unimportant but I came across something interesting as I was writing the app. When I went to handle window resizing on the application level I noticed that there was no window resizing callback being triggered when the window was minimized. I don't know if this is an error or not, all I know is that on windows the callback is triggered and on Ubuntu with KDE it is not (This is why I have narrowed down the causes of this issue to KDE not some bug in something else). I was wondering if there was an explanation for this or if maybe I found an error. Below is some code snippets from my program that are creating the behavior (I am using GLFW btw). Thanks for your time!

Code: Select all
window = glfwCreateWindow(width, height, name, nullptr, nullptr); // Create the GLFW window.
glfwSetWindowUserPointer(window, this);
glfwSetFramebufferSizeCallback(window, ResizeFrameBufferCallback);

Code: Select all
void Window::ResizeFrameBufferCallback(GLFWwindow* window, int width, int height) {
                std::cout << "SIZE: " << width << " " << height << std::endl;
                auto app = reinterpret_cast<Window*>(glfwGetWindowUserPointer(window));
                app->frameBufferResized = true;

When the window is resized the output is something like:
Code: Select all
SIZE: 600 1208

When the window is minimized I would expect something like:
Code: Select all
SIZE: 0 0

but I get nothing.

EDIT: Fixed some indentation


Who is online

Registered users: bartoloni, Bing [Bot], Google [Bot], Yahoo [Bot]