TclProp and FATCAT: Tools for Declarative Programming in Tcl

3/19/98


Click here to start


Table of Contents

TclProp and FATCAT: Tools for Declarative Programming in Tcl

Tutorial Goals

Tutorial Goals (continued)

Brief Introductions

Guide to the Tutorial

Guide to the Tutorial (cont’d)

Constraints: the Big Picture

Example #1: Fahrenheit-Celsius converter

Fahrenheit-Celsius converter with Tk interface

Fahrenheit-Celsius converter: constraint architecture

Motivation: Why Bother?

So, What Does Declarative Programming Do?

Example #2: Video Poker

Video Poker

Video Poker

Video Poker

Video Poker Question: Procedural

A Partial Answer ...

Video Poker Questions: Declarative

Writing Video Poker Declaratively

Relationships independent of “BetOne” callback and defined outside of it

But, What About Betting the Max? Dealing? Drawing?

The Declarative Way …

Another Vote for the Declarative Way

Example #3: BetSame

So, why use constraints?

Constraints in Tcl/Tk

TclProp syntax

TclProp Formulas: Fahrenheit-Celsius converter

TclProp Triggers: Video Poker

TclProp Triggers: Video Poker

Not All Interesting Values Are Stored in Variables

Traceable references allow formulas and triggers to include widget and object attributes.

Traceable References: for Widget Attributes

Traceable References: for Canvas Item Attributes

Programming Note: Quoting and Naming References

Example #4: Keeping Buttons Equally Active

Two-way relationship

Example #5: Structured Drawing

Example #6: Structured Drawing

Example #7: Your Turn!

Bonus Example

Example #8 Constraint-based color picker

Example #9: Multiple Coordinated Views

Spatial Navigation with Constraints

Trace: The Basis of TclProp

FATCAT: Extending Traces

Extending Traces with the FATCAT C API

Is it Really that Easy?

Applications & Limitations

Limitations of TclProp

How can you get started?

Conclusions

Conclusions

Current Plans

Author:

Email: safonov@cs.umn.edu

Home Page: www.cs.umn.edu/~safonov/

Other information:
Tutorial on TclProp and FATCAT at Tcl '97 Workshop

The views and opinions expressed in this page are strictly those of the page author.
The contents of this page have not been reviewed or approved by the University of Minnesota.