mail-archives/gtk-sharp-list/2004-March/003612.html

136 строки
5.5 KiB
HTML
Исходник Обычный вид История

2019-06-06 22:02:55 +03:00
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE> [Gtk-sharp-list] combo widget
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:jluke%40users.sourceforge.net">
<META NAME="robots" CONTENT="index,nofollow">
<LINK REL="Previous" HREF="003609.html">
<LINK REL="Next" HREF="003608.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[Gtk-sharp-list] combo widget
</H1>
<B>John Luke
</B>
<A HREF="mailto:jluke%40users.sourceforge.net"
TITLE="[Gtk-sharp-list] combo widget">jluke@users.sourceforge.net
</A><BR>
<I>Fri, 12 Mar 2004 12:30:36 -0500</I>
<P><UL>
<LI> Previous message: <A HREF="003609.html">[Gtk-sharp-list] combo widget
</A></li>
<LI> Next message: <A HREF="003608.html">[Gtk-sharp-list] Glade and GTK Sharp Combo Boxes
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#3612">[ date ]</a>
<a href="thread.html#3612">[ thread ]</a>
<a href="subject.html#3612">[ subject ]</a>
<a href="author.html#3612">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>On Fri, 2004-03-12 at 18:09 +0100, Borja Sanchez Zamorano wrote:
string[] is correct now, the docs in cvs will reflect this but the old
moethods were not quite removed in time for the release. This is one of
the wonderful API improvements that we got in 0.17 (i.e. the removal of
GLib.GList and GSList from the public API)
&gt;<i> In the implementation of gtk-sharp only exist PopdownStrings for
</I>&gt;<i> string[], but in the monodoc exist two. I don't understand it. Sorry.
</I>&gt;<i>
</I>&gt;<i> In gtk-sharp-0.16 exist only Combo.PopdownStrings for GLib.List
</I>&gt;<i> In gtk-sharp-0.17 exist only Combo.PopdownStrings for string[]
</I>&gt;<i>
</I>&gt;<i> BorSanZa
</I>&gt;<i>
</I>&gt;<i> El vie, 12-03-2004 a las 16:03, Roberto Díaz escribió:
</I>&gt;<i> &gt; Hello,
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; I'm using Mono 0.30 and gtk-sharp 0.17 and I'm trying to compile this
</I>&gt;<i> &gt; code:
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; using System;
</I>&gt;<i> &gt; using System.Runtime.InteropServices;
</I>&gt;<i> &gt; using Gtk;
</I>&gt;<i> &gt; using GLib;
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; class ComboSample{
</I>&gt;<i> &gt; Combo combo;
</I>&gt;<i> &gt; OptionMenu opt;
</I>&gt;<i> &gt; static void Main ()
</I>&gt;<i> &gt; {
</I>&gt;<i> &gt; new ComboSample ();
</I>&gt;<i> &gt; }
</I>&gt;<i> &gt; ComboSample ()
</I>&gt;<i> &gt; {
</I>&gt;<i> &gt; Application.Init ();
</I>&gt;<i> &gt; Window win = new Window (&quot;ComboSample&quot;);
</I>&gt;<i> &gt; win.DeleteEvent += new DeleteEventHandler (OnWinDelete);
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; GLib.List l = new GLib.List (IntPtr.Zero,
</I>&gt;<i> &gt; typeof(string));
</I>&gt;<i> &gt; l.Append(&quot;hello&quot;);
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; combo = new Combo ();
</I>&gt;<i> &gt; combo.PopdownStrings = l;
</I>&gt;<i> &gt; combo.DisableActivate ();
</I>&gt;<i> &gt; combo.Entry.Activated += new EventHandler
</I>&gt;<i> &gt; (OnEntryActivated);
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; win.Add (combo);
</I>&gt;<i> &gt; win.ShowAll ();
</I>&gt;<i> &gt; Application.Run ();
</I>&gt;<i> &gt; }
</I>&gt;<i> &gt; }
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; I get on the line &quot;combo.PopdownStrings = l&quot; this error :
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; error CS0029: Cannot convert implicitly from `GLib.List' to `string[]'
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; I've seen on monodoc that combo.PopdownStrings accepts string input and
</I>&gt;<i> &gt; GLib.List input, right?
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; How can I put GLib.List inside Gtk.Combo?
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; any idea?
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; Best regards.
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; Roberto.
</I>&gt;<i> &gt;
</I>&gt;<i> &gt;
</I>&gt;<i> &gt;
</I>&gt;<i> &gt; _______________________________________________
</I>&gt;<i> &gt; Gtk-sharp-list maillist - <A HREF="mailto:Gtk-sharp-list@lists.ximian.com">Gtk-sharp-list@lists.ximian.com</A>
</I>&gt;<i> &gt; <A HREF="http://lists.ximian.com/mailman/listinfo/gtk-sharp-list">http://lists.ximian.com/mailman/listinfo/gtk-sharp-list</A>
</I>&gt;<i> --
</I>&gt;<i> Borja Sanchez Zamorano &lt;<A HREF="mailto:borsanza@terra.es">borsanza@terra.es</A>&gt;
</I>&gt;<i>
</I>&gt;<i> _______________________________________________
</I>&gt;<i> Gtk-sharp-list maillist - <A HREF="mailto:Gtk-sharp-list@lists.ximian.com">Gtk-sharp-list@lists.ximian.com</A>
</I>&gt;<i> <A HREF="http://lists.ximian.com/mailman/listinfo/gtk-sharp-list">http://lists.ximian.com/mailman/listinfo/gtk-sharp-list</A>
</I>
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI> Previous message: <A HREF="003609.html">[Gtk-sharp-list] combo widget
</A></li>
<LI> Next message: <A HREF="003608.html">[Gtk-sharp-list] Glade and GTK Sharp Combo Boxes
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#3612">[ date ]</a>
<a href="thread.html#3612">[ thread ]</a>
<a href="subject.html#3612">[ subject ]</a>
<a href="author.html#3612">[ author ]</a>
</LI>
</UL>
</body></html>