gtk

Where GTK finds icon names to use with gtk_image_new_from_icon_name()?

一世执手 提交于 2019-12-20 18:05:15
问题 GTK can construct images by name of the "icon from current icon theme". For example: #!/usr/bin/env python import gtk; wnd=gtk.Window(); img=gtk.Image(); img.set_from_icon_name( "go-jump", gtk.ICON_SIZE_BUTTON ); wnd.add( img ); img.show(); wnd.show(); gtk.main() This will display a window with a pretty arrow inside it. But - only on ubuntu. On Windows or OSX it will display window with a "no image" icon inside :(. So my questions is - where GTK keeps icon names like "go-jump"? Is it some

GTK+-based graph?

瘦欲@ 提交于 2019-12-20 12:38:38
问题 I want to be able to make a line graph using GTK+ but I'm unsure how to approach this. Has anyone got any hints or tips? 回答1: Have a look at the gnuplot there are some C++ libraries that interface with gnuplot, which do what you are looking for and then some. It is very easy to use if you've ever used gnuplot. 回答2: Edit: Here are GTK+ 2 and GTK+ 3 versions of that program: https://github.com/liberforce/gtk-samples/tree/master/c/gtk2-graph https://github.com/liberforce/gtk-samples/tree/master

GTK# in Visual Studio 2010

痴心易碎 提交于 2019-12-20 12:15:27
问题 I've been trying all day to get GTK# working in Visual Studio 2010 on Windows Server 2008 R2 x64 so that I can start writing nice cross-platform GUI applications, but I'm somewhat new to C# and I'm having a world of trouble. I installed the latest Mono for Windows which includes GTK#. I also installed a Mono 2.10.8 profile to be the target framework of my project loosely following the guide from here: http://erictummers.wordpress.com/2012/01/25/target-mono-from-visual-studio/ I created a new

What is the relation between GTK, GTK+ and GTK2?

拈花ヽ惹草 提交于 2019-12-20 11:03:06
问题 I'm confused by the GTK terminology. According to Wikipedia, there seem to be bindings to GTK+ that are called GTK (GtkAda) and GTK2 (gtk2hs, Gtk2-Perl). Could someone clear this up for me? 回答1: GTK/GTK+ and GTK2 are different versions of the same API. GTK is an old, deprecated version, GTK2 is the previous one, GTK+ 3/GTK3 is the current version. GTK+ is the correct name of the old API, but most people just call it GTK. The C++ bindings for GTK+ are part of the project GTKmm. 回答2: The first

Your best library for create GUI ( gtk, qt, win32 api, etc )? [closed]

可紊 提交于 2019-12-20 10:27:11
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 6 years ago . In your opinion, what is the best way to create gui in Windows ? with gtk or win32 api ? Do you recommend GTK for windows ? Yes ? NO ? Why ? 回答1: Let's see. Win32 is very low-level, C based, and awkward to use. MFC is considered obsolete. C# (or C++) with .NET is probably

(Linux) How to run a program of gtk without display environment? Gtk-WARNING **: cannot open display:

走远了吗. 提交于 2019-12-20 06:38:33
问题 I got a program which must run in GTK gui environment. I can only use ssh. This program will run on a server(centos 6) and installed gnome X display. It's no need to see GUI, but after it run finished, i can get the answer. VNC and Remote screen is disable. When i start the program in ssh: Gtk-WARNING **: cannot open display: Is there any ways to salve this problem??? I known it's bad to run a gui program in this situation, but here we only discuss technology... Thank you... 回答1: The ssh

Dont kown how to fetch database?

守給你的承諾、 提交于 2019-12-20 05:46:06
问题 I'm complete beginner with sqlite and gtk. I'm making my 1st project in code::blocks. I have a problem in fetching the database my code is: #include <stdio.h> #include <stdlib.h> #include <gtk/gtk.h> #include "sqlite3.c" #include <sqlite3.h> static int callback(void *data, int argc, char **argv, char **azColName){ int i; fprintf(stderr, "%s: ", (const char*)data); for(i=0; i<argc; i++){ printf("%s = %s\n", azColName[i], argv[i] ? argv[i] : "NULL"); } printf("\n"); return 0; } int main(int

Taking a screenshot of a particular window with c/GTK [duplicate]

你离开我真会死。 提交于 2019-12-20 05:31:55
问题 This question already has an answer here : save current window as image using gtk# (1 answer) Closed last year . This is a piece of code which creates a window: #include <gtk/gtk.h> static GtkWidget* createWindow() { GtkWidget *window; window = gtk_window_new(GTK_WINDOW_TOPLEVEL); gtk_window_set_default_size(GTK_WINDOW(window), 800, 600); gtk_widget_set_name(window, "GtkLauncher"); g_signal_connect_swapped(G_OBJECT(window), "destroy", G_CALLBACK(gtk_main_quit), NULL); return window; } int

Mono return error: mono mscorlib.dll was not found

孤街醉人 提交于 2019-12-20 05:26:31
问题 I've developed a mono gtk 2.10 application with monodevelop 2.4. But, when i try to launch the .exe outside my develop machine (about 5 virtual machine) i get ever: mono mscorlib.dll was not found Also if i add mscorlib.dll to the app directory, i get the same error. Where i'm wrong ? 回答1: It might be that your program was built against a version of the runtime that isn't installed on the other machines. For instance, If you compiled against 1.1 or 4.0 and your other systems only have 2.0 or

How do I connect a custom function to the clicked action of a GTK Button?

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-20 02:49:10
问题 I am working my way through the Vala GTK+3 tutorial provided by Elementary OS. I understand that this code: var button_hello = new Gtk.Button.with_label ("Click me!"); button_hello.clicked.connect (() => { button_hello.label = "Hello World!"; button_hello.set_sensitive (false); }); uses a Lambda function to change the button's label when it's clicked. What I want to do is call this function instead: void clicked_button(Gtk.Button sender) { sender.label = "Clicked. Yippee!"; sender.set