Squeak Class Documentation category index | class index  
 
Flaps
  category: Morphic-Flaps
  superclass: Object
  subclasses:

No comment. Sorry.

instance methods
  no messages
 

class methods
  construction support
  addMorph:asElementNumber:inGlobalFlapSatisfying:
addMorph:asElementNumber:inGlobalFlapWithID:
addProjectNavigationButtonsTo:
addToSuppliesFlap:asElementNumber:
deleteMorphsSatisfying:fromGlobalFlapSatisfying:
newPartsFlapPage

  flap mechanics
  clobberFlapTabList
freshFlapsStart
reinstateDefaultFlaps
removeFlapTab:keepInList:

  menu commands
  disableGlobalFlapWithID:
disableGlobalFlaps
disableGlobalFlaps:
enableDisableGlobalFlapWithID:
enableGlobalFlapWithID:
explainFlaps

  menu support
  addIndividualGlobalFlapItemsTo:
enableGlobalFlaps
globalFlapWithIDEnabledString:
setUpSuppliesFlapOnly
showSharedFlaps
suppressFlapsString

  miscellaneous
  automaticFlapLayoutChanged
doAutomaticLayoutOfFlapsIfAppropriate
enableClassicNavigatorChanged
fileOutChanges
grabStateFromUtilities
makeNavigatorFlapResembleGoldenBar
orientationForEdge:
paintFlapButton
removeFromGlobalFlapTabList:

  new flap
  addLocalFlap
defaultColorForFlapBackgrounds
newFlapTitled:onEdge:
newFlapTitled:onEdge:inPasteUp:

  predefined flaps
  addAndEnableEToyFlaps
addNewDefaultSharedFlaps
addScriptingFlap
addStandardFlaps
initializeStandardFlaps
newLoneSuppliesFlap
newNavigatorFlap
newObjectsFlap
newPaintingFlap
newScriptingFlap
newSqueakFlap
newStackToolsFlap
newSuppliesFlap
newToolsFlap
newWidgetsFlap
quadsDefiningStackToolsFlap
quadsDefiningSuppliesFlap
quadsDefiningToolsFlap
quadsDefiningWidgetsFlap
quadsDeiningScriptingFlap

  replacement
  replaceBrowserInToolsFlap
replaceChangeSortersInToolsFlap
replaceGlobalFlapwithID:
replacePartSatisfying:inGlobalFlapSatisfying:with:
replacePartSatisfying:inGlobalFlapWithID:with:
replaceToolsFlap

  shared flaps
  addGlobalFlap:
enableOnlyGlobalFlapsWithIDs:
globalFlapTab:
globalFlapTabOrDummy:
globalFlapTabWithID:
globalFlapTabs
globalFlapTabsIfAny
positionNavigatorAndOtherFlapsAccordingToPreference
positionVisibleFlapsRightToLeftOnEdge:butPlaceAtLeftFlapsWithIDs:
removeDuplicateFlapTabs
sharedFlapsAllowed
sharedFlapsAlongBottom

instance methods
  no messages top  

class methods
  construction support top  
 

addMorph:asElementNumber:inGlobalFlapSatisfying:

If any global flap satisfies flapBlock, add aMorph to it at the given position. Applies to flaps that are parts bins and that like thumbnailing


 

addMorph:asElementNumber:inGlobalFlapWithID:

If any global flap satisfies flapBlock, add aMorph to it at the given position. No senders in the image -- intended to be invoked by doits in code updates only, and applies to flaps that are parts bins and that like thumbnailing


 

addProjectNavigationButtonsTo:

Add prev, next, and go-to buttons at the top of aContainer. This is used to create the buttons at the top of the Squeak flap


 

addToSuppliesFlap:asElementNumber:

Add the given morph to the supplies flap. To be called by doits in updates, so don't be alarmed by its lack of senders.


 

deleteMorphsSatisfying:fromGlobalFlapSatisfying:

If any global flap satisfies flapBlock, then delete objects satisfying from deleteBlock from it. Occasionally called from do-its in updates or other fileouts.


 

newPartsFlapPage

Answer a new page pasteup that will serve as a parts bin in a flap


  flap mechanics top  
 

clobberFlapTabList

Flaps clobberFlapTabList


 

freshFlapsStart

To be called manually only, as a drastic measure. Delete all flap artifacts and establish fresh default global flaps
Flaps freshFlapsStart


 

reinstateDefaultFlaps

Remove all existing 'standard' global flaps clear the global list, and and add fresh ones. To be called by doits in updates etc. This is a radical step, but it does *not* clobber non-standard global flaps or local flaps. To get the effect of the *former* version of this method, call Flaps freshFlapsStart


 

removeFlapTab:keepInList:

Remove the given flap tab from the screen, and, if aBoolean is true, also from the global list


  menu commands top  
 

disableGlobalFlapWithID:

Mark this project as having the given flapID disabled


 

disableGlobalFlaps

Clobber all the shared flaps structures. First read the user her Miranda rights.


 

disableGlobalFlaps:

Clobber all the shared flaps structures. First read the user her Miranda rights.


 

enableDisableGlobalFlapWithID:

Toggle the enable/disable status of the given global flap


 

enableGlobalFlapWithID:

Remove any memory of this flap being disabled in this project


 

explainFlaps

Flaps are like drawers on the edge of the screen, which can be opened so that you can use what is inside them, and closed when you do not need them. They have many possible uses, a few of which are illustrated by the default set of flaps you can get as described below.

'Shared flaps' are available in every morphic project. As you move from project to project, you will see these same shared flaps in each, though there are also options, on a project-by-project basis, to choose which of the shared flaps should be shown, and also momentarily to suppress the showing of all shared flaps.

To get started using flaps, bring up the desktop menu and choose 'flaps...', and make the menu stay up by choosing 'keep this menu up'. If you see, in this flaps menu, a list of flap names such as 'Squeak', 'Tools', etc., it means that shared flaps are already set up in your image. If you do not see the list, you will instead see a menu item that invites you to 'install default shared flaps'; choose that, and new flaps will be created, and the flaps menu will change to reflect their presence.

'Project flaps' are flaps that belong to a single morphic project. You will see them when you are in that project, but not when you are in any other morphic project.

If a flap is set up as a parts bin (such as the default Tools and Supplies flaps), you can use it to create new objects -- just open the flap, then find the object you want, and drag it out; when the cursor leaves the flap, the flap itself will snap closed, and you''ll be left holding the new object -- just click to place it exactly where you want it.

If a flap is *not* set up as a parts bin (such as the default 'Squeak' flap at the left edge of the screen) you can park objects there (this is an easy way to move objects from project to project) and you can place your own private controls there, etc. Everything in the default 'Squeak' flap (and all the other default flaps, for that matter) is there only for illustrative purposes -- every user will want to fine-tune the flaps to suit his/her own style and needs.

Each flap may be set up to appear on mouseover, dragover, both, or neither. See the menu items described below for more about these and other options.

You can open a closed flap by clicking on its tab, or by dragging the tab toward the center of the screen

You can close an open flap by clicking on its tab or by dragging the tab back off the edge of the screen.

Drag the tab of a flap to reposition the tab and to resize the flap itself. Repositioning starts when you drag the cursor out of the original tab area.

If flaps or their tabs seem wrongly positioned or lost, try issuing a restoreDisplay from the screen menu.

The red-halo menu on a flap allows you to change the flap's properties. For greatest ease of use, request 'keep this menu up' here -- that way, you can easily explore all the options in the menu.

tab color... Lets you change the color of the flap's tab.
flap color... Lets you change the color of the flap itself.

use textual tab... If the tab is not textual, makes it become textual.
change tab wording... If the tab is already textual, allows you to edit
its wording.

use graphical tab... If the tab is not graphical, makes it become
graphical.
choose tab graphic... If the tab is already graphical, allows you
to change the picture.

use solid tab... If the tab is not solid, makes it become solid, i.e.
appear as a solid band of color along the
entire length or width of the screen.

parts-bin behavior If set, then dragging an object from the flap
tears off a new copy of the object.

dragover If set, the flap opens on dragover and closes
again on drag-leave.

mouseover If set, the flap opens on mouseover and closes
again on mouse-leave.

cling to edge... Governs which edge (left, right, top, bottom)
the flap adheres to.

shared If set, the same flap will be available in all projects; if not, the
flap will will occur only in one project.

destroy this flap Deletes the flap.

To define a new flap, use 'make a new flap', found in the 'flaps' menu.

To reinstate the default system flaps, you can use 'destroy all shared flaps' from the 'flaps' menu, and once they are destroyed, choose 'install default shared flaps'.

To add, delete, or edit things on a given flap, it is often wise first to suspend the flap''s mouse-over and drag-over sensitivity, so it won''t keep disappearing on you while you''re trying to work with it.

Besides the three standard flaps delivered with the default system, there are two other flaps readily available on demand from the 'flaps' menu -- one is called 'Stack Tools', which provides some tools useful for building stack-like content, the other is called 'Painting', which provides a quick way to make a new painting. Simply clicking on the appropriate checkbox in the 'flaps' menu will toggle the corresponding flap between being visible and not being visible in the project.


  menu support top  
 

addIndividualGlobalFlapItemsTo:

Add items governing the enablement of specific global flaps to aMenu


 

enableGlobalFlaps

Start using global flaps, given that they were not present.


 

globalFlapWithIDEnabledString:

Answer the string to be shown in a menu to represent the status of the givne flap regarding whether it it should be shown in this project.


 

setUpSuppliesFlapOnly

Set up the Supplies flap as the only shared flap. A special version formulated for this stand-alone use is used, defined in #newLoneSuppliesFlap


 

showSharedFlaps

Answer whether shared flaps are currently showing. Presumably it is in service of Alan's wishes to have flaps show sometimes on interior subprojects and sometomes on outer projects that Bob's CurrentProjectRefactoring is threaded into the logic here.


 

suppressFlapsString

Answer the string to be shown in a menu to represent the suppress-flaps-in-this-project status


  miscellaneous top  
 

automaticFlapLayoutChanged

Sent when the automaticFlapLayout preference changes. No senders in easily traceable in the image, but this is really sent by a Preference object!


 

doAutomaticLayoutOfFlapsIfAppropriate

Do automatic layout of flaps if appropriate


 

enableClassicNavigatorChanged

The #classicNavigatorEnabled preference has changed. No senders in easily traceable in the image, but this is really sent by a Preference object!


 

fileOutChanges

Bug workaround for squeak-flap 'fileOutChanges' buttons which for a while were mistakenly sending their requests here...


 

grabStateFromUtilities

Transitional -- given that the user's system still has the old Utilities-based global flaps, do our best to bootstrap from that


 

makeNavigatorFlapResembleGoldenBar

At explicit request, make the flap-based navigator resemble the golden bar. No senders in the image, but sendable from a doit


 

orientationForEdge:

Answer the orientation -- #horizontal or #vertical -- that corresponds to the edge symbol


 

paintFlapButton

Answer a button to serve as the paint flap


 

removeFromGlobalFlapTabList:

If the flap tab is in the global list, remove it


  new flap top  
 

addLocalFlap

Menu command -- let the user add a new project-local flap. Once the new flap is born, the user can tell it to become a shared flap. Obtain an initial name and edge for the flap, launch the flap, and also launch a menu governing the flap, so that the user can get started right away with customizing it.


 

defaultColorForFlapBackgrounds

Answer the color to use, by default, in new flap backgrounds


 

newFlapTitled:onEdge:

Create a new flap with the given title and place it on the given edge


 

newFlapTitled:onEdge:inPasteUp:

Add a flap with the given title, placing it on the given edge, in the given pasteup


  predefined flaps top  
 

addAndEnableEToyFlaps

Initialize the standard default out-of-box set of global flaps. This method creates them and places them in my class variable #SharedFlapTabs, but does not itself get them displayed.


 

addNewDefaultSharedFlaps

Add the stack tools flap and the navigator flap to the global list, but do not have them showing initially. Transitional, called by the postscript of the FlapsOnBottom update; probably dispensable afterwards.


 

addScriptingFlap

Preliminary. Add a scripting flap, not in the standard set, to the list of global flaps. 'Flaps addScriptingFlap'


 

addStandardFlaps

Initialize the standard default out-of-box set of global flaps. This method creates them and places them in my class variable #SharedFlapTabs, but does not itself get them displayed.


 

initializeStandardFlaps

Initialize the standard default out-of-box set of global flaps. This method creates them and places them in my class variable #SharedFlapTabs, but does not itself get them displayed.


 

newLoneSuppliesFlap

Answer a fully-instantiated flap named 'Supplies' to be placed at the bottom of the screen, for use when it is the only flap shown upon web launch


 

newNavigatorFlap

Answer a newly-created flap which adheres to the bottom edge of the screen and which holds the project navigator controls.


 

newObjectsFlap

Answer a fully-instantiated flap named 'Objects' to be placed at the top of the screen. Not currently called; this worked once, but probably not at the moment.


 

newPaintingFlap

Add a flap with the paint palette in it


 

newScriptingFlap

Add a flap with scriptors' tools in it


 

newSqueakFlap

Answer a new default 'Squeak' flap for the left edge of the screen


 

newStackToolsFlap

Add a flap with stack tools in it


 

newSuppliesFlap

Answer a fully-instantiated flap named 'Supplies' to be placed at the bottom of the screen


 

newToolsFlap

Answer a newly-created flap which adheres to the right edge of the screen and which holds prototypes of standard tools.


 

newWidgetsFlap

Answer a newly-created flap which adheres to the bottom edge of the screen and which holds prototypes of standard widgets.


 

quadsDefiningStackToolsFlap

Answer a structure defining the items on the default system Stack Tools flap


 

quadsDefiningSuppliesFlap

Answer a list of quads which define the objects to appear in the default Supplies flap


 

quadsDefiningToolsFlap

Answer a structure defining the default Tools flap


 

quadsDefiningWidgetsFlap

Answer a structure defining the default Widgets flap


 

quadsDeiningScriptingFlap

Answer a structure defining the default items in the Scripting flap


  replacement top  
 

replaceBrowserInToolsFlap

Replace the browsers shown in the Tools flap, if any, with updated versions


 

replaceChangeSortersInToolsFlap

Get prototypes of the latest versions of the the Change Sorters into the Tools flap. Occasionally called by do-its in fileouts


 

replaceGlobalFlapwithID:

If there is a global flap with flapID, replace it with an updated one.


 

replacePartSatisfying:inGlobalFlapSatisfying:with:

If any global flap satisfies flapBlock, look in it for a part satisfying elementBlock; if such a part is found, replace it with the replacement morph, make sure the flap's layout is made right, etc.


 

replacePartSatisfying:inGlobalFlapWithID:with:

If a global flapl exists with the given flapID, look in it for a part satisfying elementBlock; if such a part is found, replace it with the replacement morph, make sure the flap's layout is made right, etc.


 

replaceToolsFlap

if there is a global tools flap, replace it with an updated one.


  shared flaps top  
 

addGlobalFlap:

Add the given flap tab to the list of shared flaps


 

enableOnlyGlobalFlapsWithIDs:

In the current project, suppress all global flaps other than those with ids in the survivorList


 

globalFlapTab:

Answer the global flap tab in the current system whose flapID is the same as aName, or nil if none found.


 

globalFlapTabOrDummy:

Answer a global flap tab in the current image with the given name. If none is found, answer a dummy StringMorph for some reason (check with tk about the use of this)


 

globalFlapTabWithID:

answer the global flap tab with the given id, or nil if none


 

globalFlapTabs

Answer the list of shared flap tabs, creating it if necessary. Much less aggressive is #globalFlapTabsIfAny


 

globalFlapTabsIfAny

Answer a list of the global flap tabs, but it they don't exist, just answer an empty list


 

positionNavigatorAndOtherFlapsAccordingToPreference

Lay out flaps along the designated edge right-to-left, possibly positioning the navigator flap, exceptionally, on the left.


 

positionVisibleFlapsRightToLeftOnEdge:butPlaceAtLeftFlapsWithIDs:

Lay out flaps along the designated edge right-to-left, while laying left-to-right any flaps found in the exception list

Flaps positionVisibleFlapsRightToLeftOnEdge: #bottom butPlaceAtLeftFlapWithIDs: #(Navigator Supplies)
Flaps sharedFlapsAlongBottom


 

removeDuplicateFlapTabs

Remove flaps that were accidentally added multiple times


 

sharedFlapsAllowed

Answer whether the shared flaps feature is allowed in this system


 

sharedFlapsAlongBottom

Put all shared flaps (except Painting which can't be moved) along the bottom