-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Fix getting paths from Uri #5139
Conversation
Without such a change font files with spaces in its name will not work |
var fileNameSegments = fileNameWithExtension.Split('.'); | ||
|
||
fileExtension = "." + fileNameSegments.Last(); | ||
var filename = Path.GetFileName(fontFamilyKey.Source.OriginalString); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is such a change necessary? It seems there used to be issues when there was a dot in the name
The search actually started with this issue :) |
|
Thanks! We shouldn't be able to use a backslash |
public void Should_Load_Single_FontAsset_With_Avares() | ||
{ | ||
var source = new Uri(AssetLocationAvares + "/Assets/YourFont.ttf"); | ||
var key = new FontFamilyKey(source); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know if this test is added correctly
Ok |
It seems to me that #2555 was already fixed in 0.9 |
Why does mono break
|
@Gillibald @kekekeks how does this look now? |
blocked #7347 |
@rstm-sf This is unblocked now, correct? |
What does the pull request do?
Fix getting paths from Uri
What is the current behavior?
Now comparison with paths is mixed: with characters without encoding and with encoded characters
What is the updated/expected behavior with this PR?
Leads to a consistent comparison with no encoded characters
How was the solution implemented (if it's not obvious)?
Use non-ascii or whitespace paths for resources
Checklist
Breaking changes
Fixed issues