Modern Interface

Show off your mod creations or just a work in progress.
User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 2:39 pm

Nystul wrote:how about an info textbox that is always there and holds the detail info. Mouse-over on item would immediately show the info in this box. I know one would have to make some free space for this ;)
but waiting even only 1 sec for a mouse-over tooltip can be tedious when looking at many items in a list...
but this of course will differ from vanilla daggerfall a bit
I've prototyped this on a local branch, but I'm struggling to adjust the text size. Either it's the same size as the rest of the text which is too large, or if I set autoSizeMode I can get the text at native resolution which is tiny. Given you've been doing quite a bit of work with the text UI components recently, I thought you might know how to change the text scaling.

User avatar
Nystul
Posts: 1383
Joined: Mon Mar 23, 2015 8:31 am

Re: Modern Interface

Post by Nystul » Mon Sep 18, 2017 3:09 pm

I could try to extend textlabel class to support label rendering with text size at a given fraction of the original text size. It would be a bit of a hack though. Maybe interkarma knows a more straight-forward way

User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 3:20 pm

No problem, I'll dive in deeper next time i get a chance. Just thought it was worth asking. :)

User avatar
Nystul
Posts: 1383
Joined: Mon Mar 23, 2015 8:31 am

Re: Modern Interface

Post by Nystul » Mon Sep 18, 2017 6:33 pm

I will try to implement this! It might be useful for talk window as well - You triggered an idea in my head :D

User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 6:39 pm

I'm going to do some more investigation right now, so I will update this thread with how it goes. I just need to understand how the existing classes function I think. Pretty sure what's there will do it, I just don't know how - yet. :)

So you may want to hold off for a couple of hours.

EDIT: Seems scaling works for TextLabel but not MultiFormatTextLabel. Continuing investigation...

User avatar
Nystul
Posts: 1383
Joined: Mon Mar 23, 2015 8:31 am

Re: Modern Interface

Post by Nystul » Mon Sep 18, 2017 7:33 pm

extended class TextLabel to support text scaling (property TextScale). Will do a pull request so you should soon be able to use it (or get the TextLabel class from my github: https://github.com/Nystul-the-Magician/ ... kingBranch).

this is how it looks (questions and answers are of different text size) - this is a temporary visualization for just showing the text scaling - talkwindow will have same text height for questions and answers for now until we decide on something else:

Image

User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 7:44 pm

Cheers I will give that a go. I can't quite understand the relationship between the text and the rect it's drawn into.. so very happy to have this.

User avatar
Nystul
Posts: 1383
Joined: Mon Mar 23, 2015 8:31 am

Re: Modern Interface

Post by Nystul » Mon Sep 18, 2017 7:46 pm

I always have to test and debug as well. I know what effect I want to achieve and what values should be computed. I just debug and adjust the computations to get there ;)

edit: i have found some issues, I will close pull request until i have the issues fixed

edit2: solved the issues, pull request incoming

User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 10:52 pm

Done. Hope everyone likes it. It only works in inventory screen where the local items list never has an icon above it.

It's switched by putting this setting to true in GUI section of settings:

EnableInventoryInfoPanel = True

You can leave tooltips on or switch them off.

EDIT: Well thats a damned letdown, after working on it all night I can't post a screenshot because the board attachment limit has been reached. Apparently. :(

User avatar
Hazelnut
Posts: 1553
Joined: Sat Aug 26, 2017 2:46 pm
Contact:

Re: Modern Interface

Post by Hazelnut » Mon Sep 18, 2017 11:42 pm

Hooray...
Attachments
itemInfoPanel.png
itemInfoPanel.png (586.48 KiB) Viewed 1791 times

Post Reply