зеркало из https://github.com/mono/mail-archives.git
231 строка
8.4 KiB
HTML
231 строка
8.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE> [Mono-osx] Runtime error with Mono 1.1.9
|
|
</TITLE>
|
|
<LINK REL="Index" HREF="index.html" >
|
|
<LINK REL="made" HREF="mailto:mono-osx%40lists.ximian.com?Subject=%5BMono-osx%5D%20Runtime%20error%20with%20Mono%201.1.9&In-Reply-To=">
|
|
<META NAME="robots" CONTENT="index,nofollow">
|
|
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
|
|
<LINK REL="Previous" HREF="000299.html">
|
|
<LINK REL="Next" HREF="000287.html">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#ffffff">
|
|
<H1>[Mono-osx] Runtime error with Mono 1.1.9</H1>
|
|
<B>Gareth Baker</B>
|
|
<A HREF="mailto:mono-osx%40lists.ximian.com?Subject=%5BMono-osx%5D%20Runtime%20error%20with%20Mono%201.1.9&In-Reply-To="
|
|
TITLE="[Mono-osx] Runtime error with Mono 1.1.9">g.j.baker at dl.ac.uk
|
|
</A><BR>
|
|
<I>Mon Sep 12 05:39:12 EDT 2005</I>
|
|
<P><UL>
|
|
<LI>Previous message: <A HREF="000299.html">[Mono-osx] MonoFramework-1.1.8.1.dmg was damaged
|
|
</A></li>
|
|
<LI>Next message: <A HREF="000287.html">[Mono-osx] Runtime error with Mono 1.1.9
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#286">[ date ]</a>
|
|
<a href="thread.html#286">[ thread ]</a>
|
|
<a href="subject.html#286">[ subject ]</a>
|
|
<a href="author.html#286">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
<HR>
|
|
<!--beginarticle-->
|
|
<PRE>I am getting a runtime error when running some macpacked SWF/mono 1.1.9
|
|
programmes. Simpler programmes seem ok (opening window and drawing to simple
|
|
canvas), but adding textbaxes or menues causes the failure.
|
|
|
|
The error is the same from a native OSX (10.4) macpacked programme and the
|
|
same programme compiled and run under X11.
|
|
|
|
The console output:
|
|
|
|
===== Sunday, September 11, 2005 10:16:53 PM Europe/London =====
|
|
Mono System.Windows.Forms Assembly [Revision: 44786; built: 2005/5/25
|
|
22:34:45]
|
|
mono[285]: Welcome to the WSX:Carbon
|
|
|
|
Unhandled Exception: System.NullReferenceException: Object reference not set
|
|
to an instance of an object
|
|
in <0x00000> <unknown method>
|
|
in (wrapper managed-to-native)
|
|
System.Windows.Forms.XplatUIOSX:GetFontMetrics (intptr,intptr,int&,int&)
|
|
in <0x00060> System.Windows.Forms.XplatUIOSX:GetFontMetrics
|
|
(System.Drawing.Graphics g, System.Drawing.Font font, System.Int32 ascent,
|
|
System.Int32 descent)
|
|
in <0x00058> System.Windows.Forms.XplatUI:GetFontMetrics
|
|
(System.Drawing.Graphics g, System.Drawing.Font font, System.Int32 ascent,
|
|
System.Int32 descent)
|
|
in <0x00434> System.Windows.Forms.Line:RecalculateLine
|
|
(System.Drawing.Graphics g, System.Windows.Forms.Document doc)
|
|
in <0x000fc> System.Windows.Forms.Document:RecalculateDocument
|
|
(System.Drawing.Graphics g, Int32 start, Int32 end, Boolean optimize)
|
|
in <0x0002c> System.Windows.Forms.Document:RecalculateDocument
|
|
(System.Drawing.Graphics g)
|
|
in <0x00038> System.Windows.Forms.TextBoxBase:CalculateDocument ()
|
|
in <0x00388> System.Windows.Forms.TextBoxBase:set_Text (System.String value)
|
|
in <0x0001c> System.Windows.Forms.TextBox:set_Text (System.String value)
|
|
in <0x0033c> MyFormProject.MainForm:InitializeComponent ()
|
|
in <0x0001c> MyFormProject.MainForm:.ctor ()
|
|
in (wrapper remoting-invoke-with-check) MyFormProject.MainForm:.ctor ()
|
|
in <0x00030> MyFormProject.MainForm:Main (System.String[] args)
|
|
Sep 11 22:17:04 Gareth-Bakers-Computer crashdump[286]: mono crashed
|
|
Sep 11 22:17:05 Gareth-Bakers-Computer crashdump[286]: crash report written
|
|
to: /Users/garethba/Library/Logs/CrashReporter/mono.crash.log
|
|
|
|
The programme and the makefile are attached.
|
|
|
|
Any help would be appreciated.
|
|
Regards
|
|
Gareth Baker
|
|
|
|
|
|
-------------- next part --------------
|
|
// project created on 24/01/2004 at 10:18
|
|
using System;
|
|
using System.Windows.Forms;
|
|
|
|
namespace MyFormProject
|
|
{
|
|
class MainForm : System.Windows.Forms.Form
|
|
{
|
|
private System.Windows.Forms.Label label2;
|
|
private System.Windows.Forms.Button convertButton;
|
|
private System.Windows.Forms.Button quitButton;
|
|
private System.Windows.Forms.Label fahrenheitText;
|
|
private System.Windows.Forms.TextBox celsiusTextBox;
|
|
private System.Windows.Forms.Label label3;
|
|
public MainForm()
|
|
{
|
|
InitializeComponent();
|
|
}
|
|
|
|
// THIS METHOD IS MAINTAINED BY THE FORM DESIGNER
|
|
// DO NOT EDIT IT MANUALLY! YOUR CHANGES ARE LIKELY TO BE LOST
|
|
void InitializeComponent() {
|
|
this.label3 = new System.Windows.Forms.Label();
|
|
this.celsiusTextBox = new System.Windows.Forms.TextBox();
|
|
this.fahrenheitText = new System.Windows.Forms.Label();
|
|
this.quitButton = new System.Windows.Forms.Button();
|
|
this.convertButton = new System.Windows.Forms.Button();
|
|
this.label2 = new System.Windows.Forms.Label();
|
|
this.SuspendLayout();
|
|
//
|
|
// label3
|
|
//
|
|
this.label3.Location = new System.Drawing.Point(128, 40);
|
|
this.label3.Name = "label3";
|
|
this.label3.TabIndex = 3;
|
|
this.label3.Text = "Celsius";
|
|
//
|
|
// celsiusTextBox
|
|
//
|
|
this.celsiusTextBox.Location = new System.Drawing.Point(8, 8);
|
|
this.celsiusTextBox.Name = "celsiusTextBox";
|
|
this.celsiusTextBox.TabIndex = 0;
|
|
this.celsiusTextBox.Text = "32";
|
|
this.celsiusTextBox.Size = new System.Drawing.Size(80,16);
|
|
//
|
|
// fahrenheitText
|
|
//
|
|
this.fahrenheitText.Location = new System.Drawing.Point(8, 40);
|
|
this.fahrenheitText.Name = "fahrenheitText";
|
|
this.fahrenheitText.TabIndex = 1;
|
|
this.fahrenheitText.Text = "0.0";
|
|
//
|
|
// quitButton
|
|
//
|
|
this.quitButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
|
this.quitButton.Location = new System.Drawing.Point(176, 80);
|
|
this.quitButton.Name = "quitButton";
|
|
this.quitButton.TabIndex = 5;
|
|
this.quitButton.Text = "Quit";
|
|
this.quitButton.Click += new System.EventHandler(this.QuitButtonClick);
|
|
//
|
|
// convertButton
|
|
//
|
|
this.convertButton.DialogResult = System.Windows.Forms.DialogResult.OK;
|
|
this.convertButton.Location = new System.Drawing.Point(72, 80);
|
|
this.convertButton.Name = "convertButton";
|
|
this.convertButton.TabIndex = 4;
|
|
this.convertButton.Text = "Convert";
|
|
this.convertButton.Click += new System.EventHandler(this.ConvertButtonClick);
|
|
//
|
|
// label2
|
|
//
|
|
this.label2.Location = new System.Drawing.Point(128, 8);
|
|
this.label2.Name = "label2";
|
|
this.label2.TabIndex = 2;
|
|
this.label2.Text = "Fahrenheit";
|
|
//
|
|
// MainForm
|
|
//
|
|
this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
|
|
this.ClientSize = new System.Drawing.Size(292, 126);
|
|
this.Controls.Add(this.quitButton);
|
|
this.Controls.Add(this.convertButton);
|
|
this.Controls.Add(this.label3);
|
|
this.Controls.Add(this.label2);
|
|
this.Controls.Add(this.fahrenheitText);
|
|
this.Controls.Add(this.celsiusTextBox);
|
|
this.Name = "MainForm";
|
|
this.Text = "Converter";
|
|
this.ResumeLayout(false);
|
|
}
|
|
|
|
[STAThread]
|
|
public static void Main(string[] args)
|
|
{
|
|
Application.Run(new MainForm());
|
|
}
|
|
|
|
void ConvertButtonClick(object sender, System.EventArgs e)
|
|
{
|
|
// get the celsiusTextField value
|
|
// and convert to Fahrenheit
|
|
// put it in the label
|
|
double celsiusTemp = Convert.ToDouble(celsiusTextBox.Text.ToString());
|
|
double fahrenheitTemp = (celsiusTemp - 32.0) * 5.00 / 9.0;
|
|
|
|
fahrenheitText.Text = fahrenheitTemp.ToString("F");
|
|
}
|
|
|
|
void QuitButtonClick(object sender, System.EventArgs e)
|
|
{
|
|
Application.Exit();
|
|
}
|
|
|
|
}
|
|
}
|
|
-------------- next part --------------
|
|
A non-text attachment was scrubbed...
|
|
Name: Makefile
|
|
Type: application/octet-stream
|
|
Size: 335 bytes
|
|
Desc: not available
|
|
Url : <A HREF="http://lists.ximian.com/pipermail/mono-osx/attachments/20050912/b18b9724/Makefile.obj">http://lists.ximian.com/pipermail/mono-osx/attachments/20050912/b18b9724/Makefile.obj</A>
|
|
</PRE>
|
|
|
|
|
|
|
|
<!--endarticle-->
|
|
<HR>
|
|
<P><UL>
|
|
<!--threads-->
|
|
<LI>Previous message: <A HREF="000299.html">[Mono-osx] MonoFramework-1.1.8.1.dmg was damaged
|
|
</A></li>
|
|
<LI>Next message: <A HREF="000287.html">[Mono-osx] Runtime error with Mono 1.1.9
|
|
</A></li>
|
|
<LI> <B>Messages sorted by:</B>
|
|
<a href="date.html#286">[ date ]</a>
|
|
<a href="thread.html#286">[ thread ]</a>
|
|
<a href="subject.html#286">[ subject ]</a>
|
|
<a href="author.html#286">[ author ]</a>
|
|
</LI>
|
|
</UL>
|
|
|
|
<hr>
|
|
<a href="http://lists.ximian.com/mailman/listinfo/mono-osx">More information about the Mono-osx
|
|
mailing list</a><br>
|
|
</body></html>
|