What gui library is used by sublime text editor? What gui library is used by sublime text editor? python python

What gui library is used by sublime text editor?


Sublime Text 2 is mostly coded in C++ and uses a custom UI toolkit. Here is the author, Jon Skinner, explaining it: http://news.ycombinator.com/item?id=2822114.

I keep meaning to write a blog post with some details on this, but as with many things, I usually end up coding instead. Sublime Text 2 is almost entirely C++ (with a smattering of Objective C for Cocoa and Python for plugins). Coding is generally fairly straight forward: code on one platform (mostly Linux at the moment, but I switch around frequently), and then make sure it still compiles elsewhere. Sublime Text 2 itself uses a custom UI toolkit. There are a lot of apps where this may not make sense, but it's not such an unreasonable choice for Sublime Text, where I always knew that a lot of the UI controls were going to have to be custom no matter the toolkit (e.g., the text control and tab controls). The UI toolkit sits on top of a cross platform abstraction layer, which is more a union of platform functionality rather than lowest common denominator.


a little Googling suggested it is using the Sublime GUI, which judging by the Debian source package is written in C++.

then again, running strings on the Linux sublime_text binary shows the following shared libraries (equivalent of Windows DLLs) which might suggest gtk:

/lib/ld-linux.so.2libgtk-x11-2.0.so.0libgdk-x11-2.0.so.0libatk-1.0.so.0libgio-2.0.so.0libpangoft2-1.0.so.0libpangocairo-1.0.so.0libgdk_pixbuf-2.0.so.0libcairo.so.2libpng12.so.0libpango-1.0.so.0libfreetype.so.6libfontconfig.so.1libgobject-2.0.so.0libgmodule-2.0.so.0libgthread-2.0.so.0librt.so.1libglib-2.0.so.0libpthread.so.0libdl.so.2libutil.so.1libm.so.6libX11.so.6libstdc++.so.6libgcc_s.so.1libc.so.6libgio-2.0.solibgio-2.0.so.0module.so

this also suggests gtk.


It might not be written in Python. The reason you see Python code is users can write scripts/plugin in Pythons to extend Sublime Text. I suspect it is written in C++ with GTK as GUI toolkit.