Algorithms for the Boolean operations and relations on shapes and labelled shapes are presented. This paper has two parts. The first part accomplishes two objectives. First, an efficient and uniform representation for shapes is presented, which is based on a linear order on the maximal lines of a shape. Second, simple and efficient algorithms for the Boolean operations on shapes (shape union, d...