简体   繁体   English

.NET等效或替代Java的GlyphVector?

[英].NET equivalent or alternative to Java's GlyphVector?

I'm in the process of porting a Java program to .NET using IKVM . 我正在使用IKVM将Java程序移植到.NET。 Unfortunately IKVM's Graphics2D implementation throws a NotImplementedException in drawGlyphVector , ie it needs to be "fleshed out" with a .NET implementation (or by reducing it to calls of other IKVM Graphics2D methods which are implemented). 不幸的是IKVM的Graphics2D的实现抛出一个NotImplementedException drawGlyphVector ,即它需要被“充实”用.NET实现(或把它简化成的实施其他IKVM Graphics2D的方法的调用)。

Any ideas for an equivalent in .NET which I could use to provide an implementation for that method in IKVM? 在.NET中我可以使用什么想法来提供在IKVM中为该方法实现的实现?


Edit #1 : My first hunch was to simply call GlyphVector.getOutline() and then fill that shape. 编辑#1 :我的第一个预感是简单地调用GlyphVector.getOutline()然后填充该形状。 Unfortunately, getOutline() threw its own NotImplementedException . 不幸的是, getOutline()抛出了自己的NotImplementedException

Well it seems that now I'm looking for an alternative to GlyphVector itself: NetGlyphVector, the IKVM version of Glyphvector is basically just a stub class with nearly all methods currently throwing NotImplementedExceptions... 那么看来现在我正在寻找一个替代GlyphVector本身:NetGlyphVector,的IKVM版本Glyphvector基本上只是一个存根类与几乎所有的方法目前扔NotImplementedExceptions ...

So does anyone know a .NET equivalent to Java's GlyphVector class? 那么有谁知道.NET与Java的GlyphVector类相当?

There is not an equivalent in .NET yet. .NET中没有相应的东西。 From Microsoft's website: 来自微软的网站:

In the Java language, this class represents a collection of glyphs and contains geometric information for the placement of each glyph in transformed coordinate space. 在Java语言中,此类表示字形集合,并包含在变换坐标空间中放置每个字形的几何信息。

In the .NET Framework, there is no direct equivalent. 在.NET Framework中,没有直接的等价物。

http://technet.microsoft.com/en-us/subscriptions/b6s81f68%28v=vs.80%29.aspx http://technet.microsoft.com/en-us/subscriptions/b6s81f68%28v=vs.80%29.aspx

You should probably just create your own class and implement the methods you need using the Java source, otherwise you will have to find another way to convert your code. 您应该只是创建自己的类并使用Java源实现所需的方法,否则您将不得不找到另一种转换代码的方法。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM