Ticket #29636 (closed defect: fixed)
mono 2.6.7 does not work with WinForms
| Reported by: | rudloff@… | Owned by: | macports-tickets@… |
|---|---|---|---|
| Priority: | Normal | Milestone: | |
| Component: | ports | Version: | 1.9.2 |
| Keywords: | Cc: | ||
| Port: | mono |
Description (last modified by ryandesign@…) (diff)
I am not sure this a MacPorts bug, but the mono port does not work when a program uses Windows.Forms :
Unhandled Exception: System.ArgumentException: The requested FontFamily could not be found [GDI+ status: FontFamilyNotFound]
Could it be a missing dependency ?
Attachments
Change History
Changed 2 years ago by rudloff@…
- Attachment swf-buttons.exe added
comment:2 Changed 2 years ago by rudloff@…
It is a C#/.net executable (from the WinForms samples) that shows the problem with mono.
comment:3 Changed 2 years ago by dremesov@…
The same bug exists under Snow Leopard too
Here is stack trace
System.Drawing.GDIPlus.CheckStatus (status=System.Drawing.Status.FontFamilyNotFound) in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/System.Drawing/System.Drawing/gdipFunctions.cs:249 System.Drawing.Font.GetHeight (dpi=96) in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:696 System.Drawing.Font.GetHeight () in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:575 System.Drawing.Font.get_Height () in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:434 System.Windows.Forms.XplatUICarbon.GetAutoScaleSize (font=) in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUICarbon.cs:2183 System.Windows.Forms.XplatUI.GetAutoScaleSize (font={[Font: Name=Microsoft Sans Serif, Size=8.25, Units=3, GdiCharSet=1, GdiVerticalFont=False]}) in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs:672 System.Windows.Forms.Form.GetAutoScaleSize (font={[Font: Name=Microsoft Sans Serif, Size=8.25, Units=3, GdiCharSet=1, GdiVerticalFont=False]}) in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Form.cs:1635 System.Windows.Forms.Form..ctor () in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_devel_mono/work/mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Form.cs:402 DicomViewer.Form1..ctor () in /Users/dmitry/projects/DICOM/OpenDICOM/other/Gobosh.Dicom/app/TestDicomViewer/Form1.cs DicomViewer.Form1.Main () in /Users/dmitry/projects/DICOM/OpenDICOM/other/Gobosh.Dicom/app/TestDicomViewer/Form1.cs:306
I have Microsoft Sans Serif installed and it's seen via fc-list
comment:4 Changed 2 years ago by dremesov@…
Sorry for unformatted stack trace
Here it is, log paths deleted for convenience
System.Drawing.GDIPlus.CheckStatus (status=System.Drawing.Status.FontFamilyNotFound) in .../mono-2.6.7/mcs/class/System.Drawing/System.Drawing/gdipFunctions.cs:249
System.Drawing.Font.GetHeight (dpi=96) in .../mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:696
System.Drawing.Font.GetHeight () in .../mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:575
System.Drawing.Font.get_Height () in .../mono-2.6.7/mcs/class/System.Drawing/System.Drawing/Font.cs:434
System.Windows.Forms.XplatUICarbon.GetAutoScaleSize (font=) in .../mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUICarbon.cs:2183
System.Windows.Forms.XplatUI.GetAutoScaleSize (font={[Font: Name=Microsoft Sans Serif, Size=8.25, Units=3, GdiCharSet=1, GdiVerticalFont=False]}) in .../mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/XplatUI.cs:672
System.Windows.Forms.Form.GetAutoScaleSize (font={[Font: Name=Microsoft Sans Serif, Size=8.25, Units=3, GdiCharSet=1, GdiVerticalFont=False]}) in .../mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Form.cs:1635
System.Windows.Forms.Form..ctor () in .../mono-2.6.7/mcs/class/Managed.Windows.Forms/System.Windows.Forms/Form.cs:402
DicomViewer.Form1..ctor () in .../Gobosh.Dicom/app/TestDicomViewer/Form1.cs
DicomViewer.Form1.Main () in .../Gobosh.Dicom/app/TestDicomViewer/Form1.cs:306
comment:5 Changed 20 months ago by ryandesign@…
- Keywords tiger removed
- Description modified (diff)
- Summary changed from mono 2.6.7 does not work with WinForms on Mac OS 10.4.11 Intel to mono 2.6.7 does not work with WinForms
Is this still a problem with mono @2.10.6? If so, you probably need to report it to the developers of mono; mono does not have a maintainer in MacPorts.


Testcase