|
Post by alexfish on Jul 9, 2020 17:29:52 GMT 1
Hi All
updated archive at post #1
hopeful this gets a bit closer to testing Mint 17 , please report if errors persist
also updated to use SHELL ie bash
BR Alex
|
|
|
Post by vovchik on Jul 9, 2020 19:22:50 GMT 1
Dear Alex,
Thanks. I am looking at the code now....
With kind regards, vovchik
|
|
|
Post by alexfish on Jul 16, 2020 3:18:14 GMT 1
Hi All After poking around have now manage to get an image into a text buffer BR Alex the code + piky OPTION UTF8 TRUE OPTION PARSE FALSE
PRAGMA OPTIONS -Wno-write-strings -Wno-pointer-arith
PRAGMA LDFLAGS `pkg-config --libs gtk+-2.0` PRAGMA OPTIONS `pkg-config --cflags gtk+-2.0`
PRAGMA INCLUDE <gtk-2.0/gtk/gtk.h>
DECLARE window TYPE GtkWidget * DECLARE text_view TYPE GtkWidget * DECLARE scrolled_window TYPE GtkWidget *
DECLARE buffer TYPE GtkTextBuffer * DECLARE pixy TYPE GdkPixbuf * DECLARE iter TYPE GtkTextIter
gtk_init (&argc, &argv)
window = gtk_window_new (GTK_WINDOW_TOPLEVEL) gtk_window_set_title (GTK_WINDOW (window), "gtk buffer") gtk_window_set_default_size (GTK_WINDOW (window), 800, 400)
buffer = gtk_text_buffer_new (NULL)
text_view = gtk_text_view_new_with_buffer (buffer) gtk_text_view_set_wrap_mode (GTK_TEXT_VIEW (text_view), GTK_WRAP_WORD)
scrolled_window = gtk_scrolled_window_new (NULL, NULL) gtk_scrolled_window_set_policy (GTK_SCROLLED_WINDOW (scrolled_window), GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC)
gtk_container_add (GTK_CONTAINER (scrolled_window), text_view); gtk_container_set_border_width (GTK_CONTAINER (scrolled_window), 5) gtk_container_add (GTK_CONTAINER (window), scrolled_window) pixy = gdk_pixbuf_new_from_file("/home/pi/bacon/BaConEyes.png",0) gtk_text_buffer_get_end_iter(buffer, &iter) gtk_text_buffer_insert_pixbuf(buffer, &iter, pixy)
gtk_widget_show_all (window)
gtk_main () Attachments:
|
|
|
Post by alexfish on Jul 22, 2020 2:27:01 GMT 1
Hi All over the last few weeks have been testing XCB as a suitable setting for the cairo/pango + making own widgets So hence there is where it will start: now :: the struggling sides aside 1. have the XCB window working with cairo, any one tried it ? , it be a funny one to configure . 2. have made with touch down of an actual terminal :: ie a pty that does not need another terminal to work I found a lib called libptytty . it be on github basic demo's do work but to get it to works as a terminal and avoid a hang , needed some hacking and a great deal of it , now need to bind the keyboard to the write out to. there is a picky, proof of concept in a XCB window bacon program , getting the columns and rows and executing stockfish and requesting a an input from the user I will be about two weeks to baconize the bits in all these are the libs xcb, xcb-keysyms, ptytty, pangocairo, cairo,X11 the actual demo / picky of comes in at 38 kib BR Alex the picky of an XCB terminal Attachments:
|
|
|
Post by vovchik on Jul 22, 2020 20:20:35 GMT 1
Dear Alex,
Good that you are making progress. We are patiently wating. Don't rush...if you don't have to.
With kind regards, vovchik
|
|
|
Post by alexfish on Aug 10, 2020 0:02:45 GMT 1
Progress widget + term + term image image print command example PRINT "\033]1337;File=name=eyes.png=;size=1;inline=0,xpos=1;ypos=1;width=128;height=128:\a" BR Alex Attachments:
|
|
|
Post by alexfish on Aug 22, 2020 20:02:19 GMT 1
Hi All
New Interface Using XCB Window and cairo
Test Code Now at POST #1
BR Alex
|
|