Closed cvdevol closed 1 year ago
Ugh. Turns out my magical tricks to make it put a dependency DLL into the main package aren't completely working.
Sorry! Should be fixed in the just published package 0.13.1.
(It may take up to an hour for it to become available on nuget.org.)
0.13.1 broke my app. "Private ReadOnly Parser As New TexFormulaParser" no longer works. Throws a "Overload resolution failed because no accessible 'New' accepts this number of arguments." error Also "Dim renderer = formula.GetRenderer(TexStyle.Display, FC.Scale, "Consolas")" throws a "'GetRenderer' is not a member of 'TexFormula' error
These statements worked fine in version 0.12
0.13.0 has several breaking changes, please take a look at the changelog.
"Private ReadOnly Parser As New TexFormulaParser" no longer works.
Try using WpfMath.Parsers.WpfTeXFormulaParser.Instance
instead.
Also "Dim renderer = formula.GetRenderer(TexStyle.Display, FC.Scale, "Consolas")" throws a "'GetRenderer' is not a member of 'TexFormula' error
There are several migration ways, depending on your usage of the resulting renderer
.
In the most common case, you'll need the following:
// Dim formula as TexFormula
Dim environment = WpfTexEnvironment.Create(TexStyle.Display, FC.Scale, "Consolas")
Dim result = formula.RenderToBitmap(environment, FC.Scale)
where RenderToBitmap
is an extension method of WpfMath.Rendering.WpfTeXFormulaExtensions
.
(I'm sorry, my VB.NET skills may not be up to date, but I did my best)
Let me know if you have any further questions.
Also, I should note that you are free to skip this 0.13 upgrade for now: it only contains breaking changes (and was released specifically to isolate the scope for further library development). Newer versions will still build on top of 0.13 API, though, so it's good if you'll let me know if any APIs of features are missing for your use cases.
VS2019 NuGet package manager gives following error when trying to update from 0.12 to 0.13
"Unable to resolve dependency 'WpfMath.Shared'. Source(s) used: 'nuget.org', 'Microsoft Visual Studio Offline Packages'.