Hi,
do pygtk still use gtk2.x? The tutorial in pygtk shows, that is the case
(http://www.pygtk.org/tutorial.html ).
Though I have found another site (non gnome,
http://python-gtk-3-tutorial.readthedocs.org/en/latest/ ) I am still to
find the official gnome document, ala pygtk.
Any idea please?
gtk+2 itself is old, and if there is no other reason, you should (since
you are new) use gtk+3.
The documentation is at https://developer.gnome.org/gtk3/3.8/
On Thu, 2013-06-27 at 14:46 +0100, Rui Pedro Caldeira wrote:
Hello guys, I'm new to GTK+ and I've run into a problem when creating a
might be not allowed due to license restrictions.
On Thu, Jun 27, 2013 at 6:09 PM, Rudra Banerjee
rudra.baner...@aol.co.uk wrote:
gtk+2 itself is old, and if there is no other reason, you should
(since you are new) use gtk+3. The documentation is at
https://developer.gnome.org/gtk3/3.8/ On Thu
help_about (GtkMenuItem *helpabout, GtkWidget *window)
{
const gchar *authors[] = {
RudraB mai...@example.com,
NULL
};
const gchar *copyright = Copyright \xc2\xa9 2012-2013 Rudra Banerjee;
const gchar *comments = _(Manage and Create BibTeX File);
gchar *hstr=g_strdup_printf(%s
I have solved the second problem (yelp only searches /usr/*, not $HOME).
Any help on the first problem please?
On Mon, 2013-06-10 at 16:53 +0100, Rudra Banerjee wrote:
Dear friends,
I am writing a code with gtk+3.
I am facing problems with linking the icons and help files with the
code
Hello gurus,
I am a novice(both in C and in gtk+), but managed to create a parser
that will create a tree from the parser.
The problem is, in the minimal example posted in fpaste, if the line
264-266 is uncommented, i.e. I parse the same file twice, I get
Pango-WARNING **: Invalid UTF-8 string
hello friends,
I am working on a gtk_list_store, that will save the rows to a file
(set_contents(file, buffer))
After saving the datas to a file, without exiting, I will like to edit
the file (as buffer) again. For that I have 2 option in my knowledge:
1) save the data, g_free(buffer),
${CC} lex.yy.c bib.tab.c `pkg-config --cflags --libs glib-2.0``pkg-config
--cflags --libs gtk+-3.0` -${LIBS} -o $@
clean:
rm -f lex.yy.c bib.tab.c ${PROG}
touch bib.l bib.y
and a sample bibtex file is:
@Book{a1,
Title=ASR,
Publisher=oxf,
author = a {\m}ook, Rudra Banerjee
Dear Friends,
I am trying to parse a bibtex file using gscanner.
The problem is that, due to many formats accepted by bibtex, it seems
bit hard to parse it.
What I mean is as long as the bibtex is of the form key=some value,
then g_scanner_get_next_token can get the string.
But it fails if it is
Below is a minimal example.
One can check the problem with key={some value} by changing, say,
author = \Chowdhury, D.\,\n
to
author = {Chowdhury, D.},\n
This can be compiled as
gcc -Wall `pkg-config --cflags --libs gtk+-3.0` glex.c
/*glex.c*/
#include glib.h
#include string.h
/* Test data */
I forget the acknowledgment:
http://www.gtkforums.com/viewtopic.php?f=3t=178159
On Mon, 2013-02-18 at 18:00 +, Rudra Banerjee wrote:
Below is a minimal example.
One can check the problem with key={some value} by changing, say,
author = \Chowdhury, D.\,\n
to
author = {Chowdhury, D.},\n
On Mon, 2013-02-18 at 19:02 +0100, David Nečas wrote:
The best approach to parse a grammar is, you know, using a parser.
So anything better then bison?
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
On Mon, 2013-02-18 at 19:02 +0100, David Nečas wrote:
The best approach to parse a grammar is, you know, using a parser.
So is there any better option then bison?
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
Can I have something like this?
in main.h
char* buffer;
void in_program(){
gtk_text_buffer_set_modified (GTK_TEXT_BUFFER(buffer), TRUE);
}
I have defined buffer to have g_file_get_contents easily.
So, any way to use gchar as gtk_text_buffer?
Friends,
I will be grateful if you kindly look at my post at
http://stackoverflow.com/questions/14700104/gscan-text-from-textview-and-store-it-in-treestore
I am not posting it here because, it contents moderate size of code
which will be better seen as formatted.
Thanks.
Hi,
I am using gtk-vim-syntax. As directed, I have copied it and :run
glib.vim which highlights my glib commands.
I tried to enable gtk3 as well by :run gtk3.vim but that is not
highlighted.
A screenshot to explain this is at http://imagebin.org/244914
, Rudra Banerjee wrote:
Dear friends, I am trying hard to get rid of file reading and editing (as
evident from my previous post) Here is a small code where I tried to open
my file in a buffer and scan. Its small, 50 line code. I will be grateful
if anybody kindly have a look and tell
Dear friends,
Please have a look at http://fpaste.org/gvF3/
So, I am writing those values to a string and then to a file(for now!)
given that, Entries e are a structure, as,
typedef struct {
GtkWidget *combo, *entry1, *entryAuth, *entryEditor, *entryTitle,
*entryPub, *entryVol,
On Wed, 2013-01-30 at 16:32 +0100, Damien Caliste wrote:
Is it clearer ?
Much clearer!
So, in a nutshell, as long as it is not free-ed, I can access it from
any other function using
char buffer
and buffer, right?
___
gtk-app-devel-list mailing list
I tried a lot(trying to understand the huge GLib as suggested by
Andrew), but most of the discussion here went way beyond my capability.
So, lets try from fresh.
My code for treeview and editing the treeview column (column Id #1). So,
once the column is edited, its updated by the cell_edited.
Dear friends,
I am trying hard to get rid of file reading and editing (as evident from
my previous post)
Here is a small code where I tried to open my file in a buffer and scan.
Its small, 50 line code.
I will be grateful if anybody kindly have a look and tell if this is
really opening the file
I tried to change alternate row color of TreeView using css as:
GtkCssProvider *provider = gtk_css_provider_new ();
gtk_css_provider_load_from_data (provider, GtkTreeView {\n
.row:nth-child(even): green;\n
.row:nth-child(odd):red;\n
}\n, -1, NULL);
GdkDisplay *display =
Dear friends,
as evident from my last few posts, I am struggling with opening a file
as buffer and write to it
(guess it has *nothing* to do with gtk, but C. Still I will be grateful
if you people kindly help).
So, first, how to open file in buffer?
/* Files opened and edited directly*/
/* FILE
wrote:
On Friday 25 January 2013 14:57:23 Rudra Banerjee wrote:
Dear friends,
as evident from my last few posts, I am struggling with opening a file
as buffer and write to it
(guess it has *nothing* to do with gtk, but C. Still I will be grateful
if you people kindly help).
So, first
,
fop,
1026,
NULL);
}
But this writes the data in unformatted form.
Can you kindly explain a bit more?
On Fri, 2013-01-25 at 17:02 +0100, Damien Caliste wrote:
Hello,
Le 25/01/2013, Rudra Banerjee rudra.baner...@aol.co.uk a écrit :
But is it so tough? database and all
Friends,
I am writing a gtk3(in C) code, that uses treeview.
store = gtk_list_store_new (NUM_COLS, G_TYPE_STRING, G_TYPE_STRING,
G_TYPE_STRING,
G_TYPE_STRING,
On Thu, 2013-01-24 at 10:45 +0100, David Nečas wrote:
Have you read the tutorial?
http://scentric.net/tutorial/sec-editable-cells.html
David,
Thanks for your reply.
Yes, I have read that tutorial.
After reading that I have learned how to make the cell editable. But the
problem still
:02:37 Rudra Banerjee wrote:
On Thu, 2013-01-24 at 10:45 +0100, David Nečas wrote:
Have you read the tutorial?
http://scentric.net/tutorial/sec-editable-cells.html
David,
Thanks for your reply.
Yes, I have read that tutorial.
After reading that I have learned how to make
Dear friends,
How can I change cell (and hence row) height of a given row?
In my treeview, I have cells of fixed width, and I want texts longer
than that should be wrapped with height increased.
Any solution anyone?
___
gtk-app-devel-list mailing list
alternative color
for each row.
On Thu, 2013-01-24 at 23:47 +, Rudra Banerjee wrote:
Thanks a lot!
worked great!
On Thu, 2013-01-24 at 15:42 -0800, Andrew Potter wrote:
On Thu, Jan 24, 2013 at 3:33 PM, Rudra Banerjee
rudra.baner...@aol.co.ukwrote:
cell = gtk_cell_renderer_text_new
Ok, no problem.
Thanks for your time though.
On Thu, 2013-01-24 at 16:21 -0800, Andrew Potter wrote:
On Thu, Jan 24, 2013 at 4:00 PM, Rudra Banerjee
rudra.baner...@aol.co.ukwrote:
gtk_tree_view_set_rules_hint (GTK_TREE_VIEW(tree), TRUE);
the rules_hint are not working, i.e. I am
Dear friends,
I have a periodic table application written in gtk2
(http://download.savannah.gnu.org/releases/ptbl/).
I wrote it in gtk2 because gnome3.4 with default gtk+ theme Adwaita do
not show colors of button for gtk3 app. Now, from gnome 3.6, this
behavior is applied in gtk2 apps as well.
I
en_GB
DISTCLEANFILES = \
Makefile.in
The problem is, yelp ghelp:app-manual says it does not point to a valid page.
But if I manually do a yelp help/C/app-manual.xml its just working fine.
Any idea?
--
Rudra Banerjee
A bus station is where a bus stops. A train station is where a train
stops
Dear friends,
In my project, I have created a SAVE AS file submenu.
I have two question:
1) This save as does not have any key board shortcut(Ctrl+S as
standard) like open or new file submenu, which are also created in the
same way, using accel group. Why this is so?
2) Though the file copying is
Dear friends,
though this might be Fedora(or gnome shell theme Adwaita) specific
problem, I cannot get color from:
GdkColor colorRed2 = {0x, 65535, 29555, 24158};
gtk_widget_modify_bg(button, GTK_STATE_NORMAL, colorRed2);
So, I am trying to use:
gtk_widget_override_background_color
Dear friends,
I have a query.
As the treeview is loaded from a file, in my program, new entries can
also be entered. It writes to the Treeview, as well as in a file using:
strAuth = gtk_entry_get_text(GTK_ENTRY(e-entryAuth));
/*Entering the data in Treeview */
gtk_list_store_append(store,
Dear friends,
I am trying to make a Treeview sortable. I have managed to get sortable
by any one column, using
GtkTreeSortable *sortable=GTK_TREE_SORTABLE(data-store);
Code:
gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(sortable),
ID_YEAR, GTK_SORT_ASCENDING);
which
Dear friends,
I am trying to make a Treeview sortable. I have managed to get sortable by any
one column, using
GtkTreeSortable *sortable=GTK_TREE_SORTABLE(data-store);
Code:
gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(sortable),
ID_YEAR, GTK_SORT_ASCENDING);
Dear friends,
below I have copied the way I am creating a treeview. Maybe, you may
find some part is not necessary, but still I put them to show you how I
am doing the things.
I need help in few things:
1) for my typical testing file, which has ~150 entry(to be parsed by
parse.sh, create file
Dear friends,
I have defined a treeview model as follows:
enum
{
COL_FIRST_NAME = 0,
COL_LAST_NAME,
COL_YEAR_BORN,
NUM_COLS
} ;
static GtkTreeModel *
create_and_fill_model (void)
{
GtkTreeStore *treestore;
GtkTreeItertoplevel, child;
treestore = gtk_tree_store_new(NUM_COLS,
Oliver,
Thanks a lot. Its working properly.
Only change that I have made is using gtk_tree_store_append in place of
gtk_tree_model_get_iter_first.
Thanks a lot again.
Regards,
On Wed, 2012-09-12 at 21:31 +0200, Olivier Sessink wrote:
On 09/12/2012 06:30 PM, Rudra Banerjee wrote:
Oliver
On Tue, 2012-09-11 at 12:16 +0700, Ardhan Madras wrote:
As I already told you, this is a basic programming error but you event
didn't notice it. So please find good C books and references out there
and start learn how to write C program.
Yes, I am also feeling that I need to learn C a fresh.
that I am using is:
Taylor, DW,
{\textbf{Banerjee, Rudra}} and Mookerjee, Abhijit and Sanyal,
Biplab,
{\textbf{R. Banerjee}} and Banerjee, M. and Majumdar, AK and
Mookerjee, A. and Sanyal, B. and Hellsvik, J. and Eriksson, O. and
Nigam, AK,
{\textbf{Rudra Banerjee
I am thinking of possibility of parsing a bibtex file with gkeyfile
parser. bibtex has the structure like:
@Book{a,
Author=b and q and r, s ,
Editor=c,
Title=d,
}
Any idea? or any other way to parse it within C(and gtk)?
___
I tried to rewrite the example given in the page
http://www.fifi.org/doc/libgtk1.2-doc/faq-html/gtkfaq-8.html
so that it can read from a file, but its not.
The code that i tried is:
#include glib.h
/* some test text to be fed into the scanner */
/*static const gchar *test_text =
( ping = 5;\n
Dear friends,
in my GTK(3) app, I am using icons as
gtk_window_set_icon(GTK_WINDOW(window),
create_pixbuf(images/icon.svg));
or
GtkWidget *ast4im = gtk_image_new_from_file (images/mkb3.png);
The problem is, when I am running the app away from the source
directory, those images are broken,
I have two file:
#THE MAIN###
#include gtk/gtk.h
int main( int argc,
char *argv[] )
{
GtkWidget *window;
GtkWidget *button;
gtk_init (argc, argv);
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
gtk_container_set_border_width (GTK_CONTAINER (window), 10);
?See: http://www.gnu.org/philosophy/no-word-attachments.html
From: Olivier Sessink oliviersess...@gmail.com
To: gtk-app-devel-list@gnome.org
Sent: Friday, 31 August 2012 4:02 PM
Subject: Re: compile multiple source file
On 08/31/2012 04:48 PM, Rudra Banerjee
Friends,
I am putting gtkbuttons inside a grid with modify_bg. I am getting an
odd case that when the window is focused, all buttons are showing white,
not what suggested by modify_bg. The same structure was working fine in
gtk2 (while I was using table instead of grid).
I am posting the complete
I will be really grateful if someone help me in the problem.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
, filestat.st_size);
free(buffer);
}
Can you please give me a hint how to write on a buffer? I am a novice,
hope you will be kind.
On Fri, 2012-08-24 at 13:33 +0100, jcup...@gmail.com wrote:
Hi Rudra,
On 23 August 2012 13:45, Rudra Banerjee bnrj.ru...@yahoo.com wrote:
whenever I am writing
Please ignore the previous post. google is giving some hints.
I will comeback if I failed.
On Fri, 2012-08-24 at 14:41 +0100, Rudra Banerjee wrote:
I am sorry but I really don't know how to write on a buffer.
I am writing on the file as:
FILE *fop = fopen(filename, a );
g_fprintf( fop
Dear friends,
I am openning an existing file in textview from command line as:
textview = gtk_text_view_new();
gtk_container_add(GTK_CONTAINER(scrolledwindow), textview);
textbuffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(textview));
if (argc 1 argv[1] != NULL) {
char
g_fprintf() or fprintf() */
see man 3 printf
Is it possible to write to a file using g_print?
g_print() already write to standard output FILE, but you can dup()
standard output to another file.
Regards.
On Wed, Aug 22, 2012 at 6:42 AM, Rudra Banerjee bnrj.ru...@yahoo.com wrote
Is it possible to write to a file using g_print?
I was trying something like:
FILE *fop = g_open(bib2.bib,w);
g_print (%s%s,strcombo,strkey, fop);
but its not working.
Even fprintf is giving warning and not writing.
mkbib.c:114:15: warning: initialization makes pointer from integer
without
Will anyone kindly show the way?
--
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
Rudra Banerjee bnrj.ru...@yahoo.com wrote:
Dear friends,
I am trying to create a textview that will show the file opens.
I have managed to make it read the commandline argument as:
stat(argv
Dear friends,
I am trying to create a textview that will show the file opens.
I have managed to make it read the commandline argument as:
stat(argv[1], filestat);
buffer = (char *) malloc(filestat.st_size * sizeof (char));
efile = fopen(argv[1], r);
fread(buffer,
in .. MEDIAFIRE
.. http://www.mediafire.com/?4l8qo1wtk35dcqb
Rudra , let me know if you will download ,
the example.
2012/6/24 Rudra Banerjee bnrj.ru...@yahoo.com
Friends,
Plz show me how to do that.
On Mon, 2012-06-18 at 23:28
Friends,
Plz show me how to do that.
On Mon, 2012-06-18 at 23:28 +0530, Rudra Banerjee wrote:
Friends,
pasted is a minimal layout of my trial to create a bibliography maker.
The problem is, in Authors tab inside notebook, I want to edit 3 more
entry, as Editor an example. But its taking
but not the least, thanks Mariano for exporting it to GTK3. its
really looks nice.
On Thu, 2012-06-21 at 11:03 -0300, Mariano Gaudix wrote:
How is the program you want to do? Can you explain?
2012/6/21 Rudra Banerjee bnrj.ru...@yahoo.com
Thanks, but its not solving the main problem
:
can you post a larger bit of the code? it is difficult to see what's going on.
b.t.w. gtk_combo_box_new_text() is deprecated, use gtk_combo_box_text_new()
Olivier
2012/6/20 Rudra Banerjee bnrj.ru...@yahoo.com:
Thanks for your reply jjacky. This is a mistake; but does not changeing
Thanks, but its not solving the main problem.
/
2012/6/20 Rudra Banerjee bnrj.ru...@yahoo.com
Olivier,
Thanks for your interest.
Pasted just below is the complete code
(GTK_COMBO_BOX(widget));
fprintf(stdout, %s, bibtype);
which is giving error. I am trying hard via tutorials in web from
yesterday. Please help.
On Mon, 2012-06-18 at 20:35 +0200, David Nečas wrote:
On Mon, Jun 18, 2012 at 11:28:48PM +0530, Rudra Banerjee wrote:
pasted is a minimal layout of my
Thanks for your reply jjacky. This is a mistake; but does not changeing
the result.
On Tue, 2012-06-19 at 22:13 +0200, jjacky wrote:
On 06/19/12 21:43, Rudra Banerjee wrote:
Yeti, Thanks for your help. That is working now.
it should probably be GTK_COMBO_BOX(combo), not GTK_COMBO_BOX(widget
Friends,
pasted is a minimal layout of my trial to create a bibliography maker.
The problem is, in Authors tab inside notebook, I want to edit 3 more
entry, as Editor an example. But its taking only the first entry.
Please show me where I am making the error.
(NB. I am neither a C programmer nor
Is it possible to show a minimal example(or a webpage with such
tutorial?)? or atleast direct me where I need to make change?
Rudra Banerjee
JRF, SNBNCBS
http://www.bose.res.in/~rudra
প্রতিদিন সূর্য ওঠে তোমায় দেখবে বলে,
ও আমার আগুন তুমি আবার ওঠো জ্বলে
If possible, plz. don't send me MsWord
Friends,
I have an xml file.
I want to search its Author and Year from GTK entry.
The xml file looks like this:
xml
records
record
database name=My Collection.enl path=My Collection.enlMy
Collection.enl/database
ref-type name=Journal Article0/ref-type
contributors
authors
authorBanerjee,
Thanks Emmanuel and xiaohu
I am new to GTK and C programming. Hence don't know things.
Both of your reply helped me to find things out.
Google said libxml2 is the standard way, where markup is not so
standard to parse xml. I think I will stick to libxml2.
On Sun, 2012-05-27 at 11:39 +0530, Rudra
Friends,
Please check the program:
#include stdio.h
#include gtk/gtk.h
#include gdk/gdk.h
#include curl/curl.h
GtkWidget *Bar;
size_t my_write_func(void *ptr, size_t size, size_t nmemb, FILE *stream)
{
return fwrite(ptr, size, nmemb, stream);
}
size_t my_read_func(void *ptr, size_t size,
Thanks ... its working!
On Thu, 2012-05-24 at 19:19 +0200, David Nečas wrote:
On Thu, May 24, 2012 at 10:37:01PM +0530, Rudra Banerjee wrote:
$ gcc curlgtk.c -o cpan `pkg-config --cflags gtk+-2.0` `pkg-config
--libs libcurl gtk+-2.0`
/usr/bin/ld: /tmp/ccZN7P8Q.o: undefined reference
kindly show me a simple code in C that can fetch data from
google scholar with Import into bibtex entry on?
Best and Regards,
--
Rudra Banerjee
If possible, plz. don't send me MsWord/PowerPoint mails. Why? See
http://www.gnu.org/philosophy/no-word-attachments.html
:18 +0200, David Nečas wrote:
On Fri, May 18, 2012 at 09:12:45PM +0530, Rudra Banerjee wrote:
Here is a minimal example of a program, where if i click the button, a
pop up window appears. I am posting both the call back function and the
main routine (table.c).
I am facing 2 problem
Can anybody please take some time to show me simple way of implementing pango
formatting to get greek letters, subscripts and superscripts in gtk2+?
A minimal(complete with headers) example will be very appriciated.
--
Rudra
JRF; SNBNCBS
http://www.bose.res.in/~rudra
A bus station is where a
Friends,
How can I convert gtk_entry_set_text to an integer/real number?
Below is a minimal example. Please suggest.
#include stdio.h
#include gtk/gtk.h
void enter_callback( GtkWidget *widget,
GtkWidget *entry )
{
gchar *entry_text;
entry_text =
-0400, Rudra Banerjee wrote:
Friends,
How can I convert gtk_entry_set_text to an integer/real number?
Below is a minimal example. Please suggest.
#include stdio.h
#include gtk/gtk.h
void enter_callback( GtkWidget *widget,
GtkWidget *entry )
{
gchar *entry_text
Dear friends,
I am a newbie in GTK and also in C itself. I am trying to develop a
table (thanks to awesome tutorials available). I am currently facing a
problem.
In the given code, its working fine. Posted is a minimal example I
managed to generate. The problem is in line 88 and 89, either of
Dear Friends,
I have taken a project (my own, not homework) to develop a table. I
generally work with fortran, don't know C that much.
What I want is a gtk clist to pop up when I press a button, via
callback. The button widget in my code is
/* Create first button */
button =
77 matches
Mail list logo