NPBruce / valkyrie

Valkyrie GM for Fantasy Flight Board Games
Apache License 2.0
506 stars 105 forks source link

Text box constraints #553

Closed LordPyrex closed 6 years ago

LordPyrex commented 7 years ago

I've noticed that some of the text box constraints are causing fit issues. Is this still ongoing or is this just something that is on my end. Using v1.3

NPBruce commented 7 years ago

Are you talking about in the editor or while playing? Which boxes? in 1.4 I am changing the editor text boxes to grow/shrink to fit the text size.

LordPyrex commented 7 years ago

In play. I'm sure with the next roll out it won't be a problem.

NPBruce commented 7 years ago

I am not aware of any issues in play, if you can reproduce one please tell me where, and and what resolution you are running.

LordPyrex commented 7 years ago

constraint I'm not sure if it's just quantity based, but I was able to reproduce on 1920x1200 windowed and 3840x2160 Fullscreen

NPBruce commented 7 years ago

Can you provide the scenario? I don't have a monitor that big so I will do what I can do find out what is going on.

NPBruce commented 7 years ago

I just want the event text to reproduce the problem... though it may be tricky if it doesn't occur at lower resolutions.

LordPyrex commented 7 years ago

Just the event.ini?

LordPyrex commented 7 years ago

Or the actual text from the event

NPBruce commented 7 years ago

Doesn't matter, I will pull it from you scenario.

LordPyrex commented 7 years ago

I've been able to eliminate it by adding a leading blank line, but noticed it happen on other events. I'll check the next alpha to see how that affects things before doing some over hauling

NPBruce commented 7 years ago

The development branch has no changes in this area.

EtiCarasoft commented 7 years ago

I've found this problem using 1.3 version too but in spanish version for the lower menu: 1440x900 Windowed captura de pantalla 2017-06-28 a les 19 35 14

redwolf2 commented 7 years ago

@EtiCarasoft

You can change the ... https://github.com/NPBruce/valkyrie/blob/development/unity/Assets/Resources/Text/Localization.txt

... and have to change: ITEMS_SMALL and SET

LordPyrex commented 7 years ago

@NPBruce I think that this has been resolved with any current iterations. I feel at this point this thread could be closed unless there are other issues floating around out there.

NPBruce commented 7 years ago

@LordPyrex I haven't changed anything here since 1.3, so I am not sure how/why this is fixed. Are you no longer able to produce the issue shown in the screen shot above?

LordPyrex commented 7 years ago

Well, as quickly as I said that I noticed another box with this issue.... never mind for now...

Indoy commented 6 years ago

@NPBruce Hi! I also have some trouble to fit correctly text window with my translations. Most of the time it's out the frame. I did not catch if there's any issue for that? I have tried to delete some "\n", maximised my translation w/o loosing original meanings...don't know what to do. Thank you Here, the upper sentence is unseen. image

NPBruce commented 6 years ago

In this case that is the maximum size available.

The scenario could be reworked to split this into two.

redwolf2 commented 6 years ago

Can't we just show scrollbars on demand?

NPBruce commented 6 years ago

No because of the black text unity bug. In general though, I'm not sure that such a wall of text in a single event is a great idea.

If someone wants this add as a feature request (this is not related to this issue).

Indoy commented 6 years ago

OK! nevermind, in the future i'll ensure to the translated text fill the box... even if i have to cut a little the original idea! Thx

bluefishj commented 6 years ago

I've had the same issues with my scenario, The Experiment. I was had not looked it up and was hoping it was a known issues that would be fixed in 2.0, but I'm still able to reproduce it. I've tested it on different resolutions on Mac, PC, and Android, all able to reproduce. Start scenario, two token in middle of room, dagger -> stab -> triggers EventInvestigatorAwakes, takes less than a minute to reproduce. If I open the event, add and remove a space in the text box, then save and test, it fixes it, but doesn't fix it for the exported package. It will stay fixed if I go play in the app right after using the editor, but if I quit the app an then reopen, the text has problems again. I think there were at least a few instances of this when I was testing, but didn't write them down at the time. I know it happens again when you threaten the first NPC. The text boxes are smaller than other text boxes in the scenario, so they should fit. Not sure why they are getting cropped.

screen shot 2018-05-06 at 11 59 08 pm

Bakajao commented 6 years ago

Hi all...i had the same problem about the boxes text fit...i investigated why happens and i discover that it fix changing the languaje in quest.ini file.... I hope that solution solve the problems

BenRQ commented 6 years ago

Hi @Bakajao, I have the same issue and I tried to change the default language but it did not fix the issue. I set DefaultLanguage to French, and my text is in French. Valkyrie version 2.0.1

Can you give more details on your fix ?

momtextsize

BenRQ commented 6 years ago

@NPBruce @redwolf2 I have a fix to propose on this one.

It seems that Unity may not provide a correct height when using GetPreferredHeight in some cases. I tried to attach the object and use Canvas.ForceUpdateCanvases(); to see if it was related but it's not.

It does work fine when using the UIElement that you are going to display though. So I changed the functions so they are not static anymore, but using the Object itself. And it works just fine now :)

image

Tell me if you are happy with this fix, I will pull this to development.

redwolf2 commented 6 years ago

You can always make a pull request. Seems fine by me.

BenRQ commented 6 years ago

Pull request #866

BenRQ commented 6 years ago

Beta test version is now available with implementation of this issue: https://github.com/BenRQ/valkyrie/releases/tag/release%2F2.1%2FBrynhildr_2.1.0b

Please close if you are happy with the fix