O'Reilly logo

Erlang Programming by Simon Thompson, Francesco Cesarini

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 14. GUI Programming with wxErlang

Programming graphical user interfaces (GUIs) is not one of Erlang’s touted strengths, but ongoing work has provided Erlang with a cross-platform, state-of-the-art GUI programming system: wxErlang, an Erlang binding of the wxWidgets system.

wxWidgets consists of an extensive C++ library that provides components for building menus, buttons, interactions, text and graphical displays, and much more; wxWidgets also provides a general framework for building cross-platform applications, including support for internationalization, and lower-level facilities such as memory management. Because of the size and complexity of wxErlang, this chapter cannot provide a comprehensive overview of it. Instead, this chapter covers the principles underlying the toolkit and provides a taste of some of its most-used aspects. Our coverage should be enough to get you started and give you the base from which to explore the library in more depth.

This chapter introduces wxWidgets and explains the principles underlying its Erlang binding. After describing the event-handling mechanism in wxErlang, we present a scaled-down blog example in two stages. This chapter concludes with a number of pointers for learning more about wxWidgets and wxErlang, and a series of exercises to improve and extend the running example.

wxWidgets

The wxWidgets open source project was initiated by Julian Smart in the early 1990s, and it is now supported by a team of approximately 20 developers and ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required