FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

TextView Syntax Highlight

 
Post new topic   Reply to topic     Forum Index -> gtkD
View previous topic :: View next topic  
Author Message
Mengu



Joined: 21 Mar 2010
Posts: 21

PostPosted: Tue Mar 23, 2010 12:45 pm    Post subject: TextView Syntax Highlight Reply with quote

Hi,

I am building a programming editor with gtkD and I would like to know which path should I follow in order process syntax highlighting to the content of my text view.

Thanks.
_________________
mengu.net - some kind of monster
Back to top
View user's profile Send private message
Mengu



Joined: 21 Mar 2010
Posts: 21

PostPosted: Tue Mar 23, 2010 1:27 pm    Post subject: Reply with quote

alright, i have found that i can use GtkSourceView with D so I am going to use it. however I cannot build my simple example.

i'm trying to build my simple file like this: dmd button-test.d -I~/projects/gtkD/src -I~/projects/gtkD/srcsv -L-L~/projects/gtkD/src -L-L~/projects/gtkD/srcsv -L-lgtkd -L-ldl

but this fails. i'm missing something but i don't know what is it.

edit: i have tried to compile like dmd button-test.d -I~/projects/gtkD/src -I~/projects/gtkD/srcsv -L-ldl -L-L~/projects/gtkD/src -L-L~/projects/gtkD/srcsv -L-lgtkd -L/home/mengu/projects/gtkD/libgtkdsv.a

but i got this error:

http://paste.pocoo.org/show/192989/

by the way, i have installed gtkD like this:
- download from trunk
- run make

and i am able to use all gtk features. except the sourceview.
_________________
mengu.net - some kind of monster
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Tue Mar 23, 2010 3:16 pm    Post subject: Reply with quote

Link gtkdsv before gtkd like so:

dmd button-test.d -I~/projects/gtkD/src -I~/projects/gtkD/srcsv -L-ldl -L-L~/projects/gtkD/src -L-L~/projects/gtkD/srcsv -L-lgtkdsv -L-lgtkd

You could also use --start-group and --end-group so ld searches the libraries recursively for dependencies, but im not sure you can pass them trough dmd.
Back to top
View user's profile Send private message
Mengu



Joined: 21 Mar 2010
Posts: 21

PostPosted: Tue Mar 23, 2010 5:44 pm    Post subject: Reply with quote

Mike Wey wrote:
Link gtkdsv before gtkd like so:

dmd button-test.d -I~/projects/gtkD/src -I~/projects/gtkD/srcsv -L-ldl -L-L~/projects/gtkD/src -L-L~/projects/gtkD/srcsv -L-lgtkdsv -L-lgtkd

You could also use --start-group and --end-group so ld searches the libraries recursively for dependencies, but im not sure you can pass them trough dmd.


Thank you Mike, this is working great.
_________________
mengu.net - some kind of monster
Back to top
View user's profile Send private message
Epileg



Joined: 10 Sep 2009
Posts: 77

PostPosted: Tue Mar 30, 2010 12:42 pm    Post subject: Reply with quote

I build periodically deb packages of gtkd. During the installation process, the package modifies the "/etc/dmd.conf" file to assure that dmd will compile correctly applications with gtkd.

But now I see that the order of the linking is important and I don't know what's the right way to do that.

Also I don't know how to correctly use "--start-group" and "--end-group".

Thanks in advance.
Back to top
View user's profile Send private message
Mike Wey



Joined: 07 May 2007
Posts: 428

PostPosted: Wed Mar 31, 2010 2:10 pm    Post subject: Reply with quote

Just make sure libgtkd is the last on the list of gtkd libraries it should be the only one that matters, since there are no dependencies between the other libraries.
Back to top
View user's profile Send private message
Epileg



Joined: 10 Sep 2009
Posts: 77

PostPosted: Wed Mar 31, 2010 2:47 pm    Post subject: Reply with quote

Ok, thanks a lot!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic     Forum Index -> gtkD All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group