Harry George Harry George, Public Domain, 1997

# X/Motif Hello World in Modula3

This is an example of programming X/Motif in Modula3. It is further documented with the m3doc system.

## Table of Contents

## Introduction

Modula3 can use `C` libraries such as X and Motif. To do so it needs:

- Bindings, in the form of interface `.i3` files. These were generated by automated and manual transformations of the equivalent C code or original specifications.
- Patterns to handle C's macros and vararg constructs. These are captured in the `Xmacro` module.
- Patterns to protect as much type safety as practical. These are demonstrated in this application, in the `ui_motif` subdir.

## Appendix

- src: The basic application
  - m3makefile
  - Main .m3
  - AppModel .i3 .m3
  - UI .i3 .m3
- ui_motif: The Motif-specific user interface
  - m3makefile
  - MainWindow .i3 .m3
  - Menu .i3 .m3
  - Toolbar .i3 .m3