<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE TIP SYSTEM "http://tcl.activestate.com/cgi-bin/tct/tip/tipxml.dtd">
<!-- Converted at Thu Feb 09 12:21:13 GMT 2012 -->
<!-- TIP AutoGenerator - written by Donal K. Fellows -->

<TIP number='71'>
<header><title>Tk Bitmap Image Improvements</title><author address="mailto:chris@pinebush.com">Chris Nelson</author><author address="mailto:kennykb@acm.org">Kevin Kenny</author><author address="mailto:ericm@interwoven.com">Eric Melski</author><author address="mailto:donal.k.fellows@man.ac.uk">Donal K. Fellows</author><status type='project' state='withdrawn' tclversion="8.5" vote='prior'>$Revision: 1.14 $</status><history></history><created day='26' month='oct' year='2001' /></header>
<abstract>Tk has a number of pre-defined bitmaps (10 on all platforms) but it lacks a number of bitmaps useful for creating GUI elements. This TIP adds several such bitmaps (as bitmap images).</abstract>
<body><section title="New Bitmaps">
<para>Many complex widgets like comboboxes, spinboxes, etc. require arrows pictures on buttons. While newer releases of Tk have added more widgets, there will always be some unforeseen need for new or customized widgets. One example is a menubutton which, according to the Microsoft Windows User Experience [<url ref="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwue/html/welcome.asp"/>], should have a downward arrow on the right side. With compound buttons, it is not hard to do:</para>
<verbatim><vline encoding='base64'>ICAgYnV0dG9uIC5tYiAtdGV4dCBUb29scyAtaW1hZ2UgZG93bmFycm93IC1jb21wb3VuZCByaWdodA==</vline></verbatim>
<para>but there is no stock down-arrow image. </para>
<para>I propose to add 12 bitmap images providing all four directions (up, down, left, and right) in three sizes (3x2, 5x3, and 7x4) in black. The down arrows would look something like:</para>
<verbatim><vline encoding='base64'>ICAgQEBAQEBAQCAgIEBAQEBAICAgICAgQEBA</vline><vline encoding='base64'>ICAgLkBAQEBALiAgIC5AQEAuICAgICAgLkAu</vline><vline encoding='base64'>ICAgLi5AQEAuLiAgIC4uQC4uICAgIA==</vline><vline encoding='base64'>ICAgLi4uQC4uLg==</vline></verbatim>
<para>I propose the following names:</para>
<verbatim><vline encoding='base64'>ICAgYXJyb3dfdTd4NCAgICAgIGFycm93X3U1eDMgICAgICBhcnJvd191M3gy</vline><vline encoding='base64'>ICAgYXJyb3dfZDd4NCAgICAgIGFycm93X2Q1eDMgICAgICBhcnJvd19kM3gy</vline><vline encoding='base64'>ICAgYXJyb3dfbDd4NCAgICAgIGFycm93X2w1eDMgICAgICBhcnJvd19sM3gy</vline><vline encoding='base64'>ICAgYXJyb3dfcjd4NCAgICAgIGFycm93X3I1eDMgICAgICBhcnJvd19yM3gy</vline></verbatim>
<para>I&apos;m mindful of the fact that adding new predefined bitmap images has the potential to collide with application-defined images or other commands but I&apos;m unsure of the workaround for that.</para>
</section>
<section title="Reference Implementation">
<para>SourceForge patch 475332 provided a reference implementation of a previous version of this proposal [<url ref="http://sf.net/tracker/?func=detail&amp;aid=475332&amp;group_id=12997&amp;atid=312997"/>]. This version is not implemented yet.</para>
</section>
<section title="Commentary">
<para><emph style="italic">Donal K. Fellows &lt;<url ref="mailto:donal.k.fellows@man.ac.uk"/>&gt; writes:</emph></para>
<quote>Previous versions of this TIP proposed fixing the problem using bitmaps instead of bitmap images and added an infrastructure for tracking those bitmaps. Since I think that ultimately we should be getting rid of bitmaps and instead using something based on the image infrastructure (which already has proper introspection support) those parts of this TIP have been removed. However, making the changes to effect the switch to using bitmap images instead of bitmaps for things like stippes, cursors, etc. lies outside the scope of this TIP.</quote>
<para><emph style="italic">Donal K. Fellows &lt;<url ref="mailto:donal.k.fellows@man.ac.uk"/>&gt; writes:</emph></para>
<quote>In the long period since this TIP was proposed, the world of GUIs has moved on somewhat. Although the requirement for arrows remains the same, the solutions proposed in this TIP (both originally and as it now stands) do not permit the sort of graphical snazziness that modern users tend to expect. Nor is there a sufficient range of sizes for a reasonable selection to be available for a modern display; even the largest of those arrows would look unusably tiny on my desktop! This indicates that a completely different solution is required, which in turn would be better stated as a separate TIP.</quote>
</section>
<section title="Copyright">
<para>This document has been placed in the public domain.</para>
</section>
</body></TIP>

