The Wayback Machine - https://web.archive.org/web/20220512212513/https://github.com/obsproject/obs-studio/issues/5910
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[27.2] The text area is getting smaller and smaller than 27.1.3 #5910

Open
iesvme opened this issue Feb 3, 2022 · 9 comments
Open

[27.2] The text area is getting smaller and smaller than 27.1.3 #5910

iesvme opened this issue Feb 3, 2022 · 9 comments
Labels
Good first issue

Comments

@iesvme
Copy link

@iesvme iesvme commented Feb 3, 2022

Operating System Info

Windows 10

Other OS

No response

OBS Studio Version

27.2.0 Beta 4

OBS Studio Version (Other)

No response

OBS Studio Log URL

https://obsproject.com/logs/QMXmDkcbbTOBe2uO

OBS Studio Crash Log URL

No response

Expected Behavior

Remember the resized window.

Current Behavior

The preview window is too big and wastes a lot of space, but the commonly used editing area is too small, so that it's not convenient to edit or adjust text. And the default text area is too far to the bottom and not convenient for writing. I always have to resize it manually every time. The user experience is not good. Is it possible to remember the resized window?
11

Steps to Reproduce

  1. Add a text source
  2. Click the Properties

Anything else we should know?

No response

@Fenrirthviti
Copy link
Member

@Fenrirthviti Fenrirthviti commented Feb 3, 2022

There is a separator between the text preview and the options, simply drag it to make the preview larger or smaller as you want.

@WizardCM
Copy link
Member

@WizardCM WizardCM commented Feb 3, 2022

For reference, I did some digging for this 2 days ago.

  1. This code says that the view should be a 3:1 stretch
    windowSplitter->setStretchFactor(0, 3);
    windowSplitter->setStretchFactor(1, 1);
  2. However, no matter how tall you open the Properties window, the properties section always has the exact same height
  3. I think this is due to the Preview requesting a full stretch without the parent view knowing how tall it is properly.

If I completely remove the stretch factor & preview->sizePolicy it behaves better, but still not 3:1 or anything useful.

I don't believe this is new to 27.2 though.

@Fenrirthviti
Copy link
Member

@Fenrirthviti Fenrirthviti commented Feb 3, 2022

Ah, sorry, I see what you mean now, the size is not being saved. Can you confirm if this is new to 27.2 or if you experienced this in previous versions?

@Fenrirthviti Fenrirthviti reopened this Feb 3, 2022
@iesvme
Copy link
Author

@iesvme iesvme commented Feb 3, 2022

For reference, I did some digging for this 2 days ago.

  1. This code says that the view should be a 3:1 stretch
    windowSplitter->setStretchFactor(0, 3);
    windowSplitter->setStretchFactor(1, 1);
  2. However, no matter how tall you open the Properties window, the properties section always has the exact same height
  3. I think this is due to the Preview requesting a full stretch without the parent view knowing how tall it is properly.

If I completely remove the stretch factor & preview->sizePolicy it behaves better, but still not 3:1 or anything useful.

I don't believe this is new to 27.2 though.

Thanks for your reply.
It would also be nice if the default ratio was adjusted to a 1:1 instead of 3:1.

@WizardCM
Copy link
Member

@WizardCM WizardCM commented Feb 3, 2022

In my opinion the ratio should be highly dependent on the size of the preview section. If the source is wider than it is tall, then the properties should take up more space (as is the case with the text source). For sources that are tall but also have a lot of properties, I think 1:1 or 2:1 would be best.

@iesvme
Copy link
Author

@iesvme iesvme commented Feb 3, 2022

And I thought we were usually working on the editing area, and the preview window was sufficient with a small window.

@kkartaltepe kkartaltepe added the Good first issue label Apr 1, 2022
@eruhlinteractive
Copy link

@eruhlinteractive eruhlinteractive commented May 1, 2022

Hey there! I'm new to the project and would like to try and tackle this issue. Lines 111-112 seemed to have moved from obs-studio/UI/window-basic-properties.cpp in the master branch. Any advice on where to start looking, or should this issue be resolved in the releases/27.2 branch?

@WizardCM
Copy link
Member

@WizardCM WizardCM commented May 1, 2022

@ebot102 That is due to the merging of #6088, I expect the code to look at is not in the Properties window at all, but rather something deep in https://github.com/obsproject/obs-studio/blob/master/UI/qt-display.cpp where it adapts its size to the content regardless of the container it's in.

@eruhlinteractive
Copy link

@eruhlinteractive eruhlinteractive commented May 1, 2022

So I see where it is resizing the content in https://github.com/obsproject/obs-studio/blob/master/UI/qt-display.cpp (lines 213-216)

if (isVisible() && display) {
		QSize size = GetPixelSize(this);
		obs_display_resize(display, size.width(), size.height());
	}

However, the only place I have been able to find that the scaling ratios are set is in https://github.com/obsproject/obs-studio/blob/master/UI/forms/OBSBasicProperties.ui under the "propertiesFrame" tag. Is this the correct place to edit the ratio for text boxes, or is this defining the scaling ratios for the parent container?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Good first issue
5 participants