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

Code is not highlighted correctly in reading mode #27

Closed
marchank0 opened this issue Oct 24, 2022 · 5 comments
Closed

Code is not highlighted correctly in reading mode #27

marchank0 opened this issue Oct 24, 2022 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@marchank0
Copy link

Editing mode:
obs-code-editing

Reading mode - BUG:
obs-code-reading

@harmtemolder harmtemolder self-assigned this Nov 21, 2022
@harmtemolder harmtemolder added the bug Something isn't working label Nov 21, 2022
@harmtemolder
Copy link
Owner

Should be fixed with the new release. Could you test, please?

@marchank0
Copy link
Author

marchank0 commented Nov 22, 2022

@harmtemolder
it's better, but as you can see there is a noticeable difference in highlighting

6A3D9784-CE62-49CD-9B0F-7E0FB474B2AD
B6501E66-375B-4DA7-BC3F-E5D1B64780B3

class BinarySearch:
	def search(self, nums: List[int], target: int) -> int:
		l = 0
		r = len(objects) - 1
		while (l <= r):
			mid = (l + r) // 2
			guess = objects[mid]
			if (guess == target):
				return mid
			if (guess > target):
				r = mid
			else:
				l = mid + 1
		return None

@harmtemolder
Copy link
Owner

Thanks for pointing that out.

I went through all the code colors again, trying to match these as closely to the Python examples here: https://ethanschoonover.com/solarized/#python-vim

This is the result:

Editing view:

image

Reading view:

image

The fact that they are not 100% consistent (the None) is because Obsidian's own CSS is not 100% consistent. But I hope this is close enough for you.

@marchank0
Copy link
Author

@harmtemolder
this is splendid work!

@harmtemolder
Copy link
Owner

Haha, you're welcome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants