log in | register | forums
Show:
Go:
Forums
Username:

Password:

User accounts
Register new account
Forgot password
Forum stats
List of members
Search the forums

Advanced search
Recent discussions
- Elsear brings super-fast Networking to Risc PC/A7000/A7000+ (News:)
- Latest hardware upgrade from RISCOSbits (News:)
- WROCC November 2024 talk o...ay - Andrew Rawnsley (ROD) (News:3)
- Accessing old floppy disks (Gen:3)
- November developer 'fireside' chat on saturday night (News:)
- RISCOSbits releases a new laptop solution (News:4)
- Announcing the TIB 2024 Advent Calendar (News:2)
- RISC OS London Show Report 2024 (News:1)
- Code GCC produces that makes you cry #12684 (Prog:39)
- Rougol November 2024 meeting on monday (News:)
Latest postings RSS Feeds
RSS 2.0 | 1.0 | 0.9
Atom 0.3
Misc RDF | CDF
 
View on Mastodon
@www.iconbar.com@rss-parrot.net
Site Search
 
Article archives
Acorn Arcade forums: Programming: Select changes?
 
  Select changes?
  Chris (14:30 1/5/2004)
 
Chris Message #53935, posted by Chris at 14:30, 1/5/2004
Member
Posts: 283
My BASIC library has a couple of PROCs to change icon attributes, such as background colour and the validation string. These have been working fine. Then I upgraded to Select, and they've stopped working, causing odd behaviour. Is there anything wrong with the code below? If not, I guess I'll have to email ROL to see if behaviour has changed under Select.


PROCicon_setval (window%,icon%,text$)
REM Sets icon validation string
block%!0=window%:block%!4=icon%
SYS "Wimp_GetIconState",,block%
$(block%!32)=text$:block%!8=0:block%!12=0
SYS "Wimp_SetIconState",,block%
ENDPROC

PROCicon_setbackground (window%,icon%,colour%)
REM Sets an icon's background to a colour from Wimp palette
block%!0=window%:block%!4=icon%
block%!8=0:block%!12=block%!12 OR (%1111<<28 )
SYS "Wimp_SetIconState",,block%
block%!8=block%!8 OR (colour%<<28 )
block%!12=block%!12 OR (colour%<<28 )
SYS "Wimp_SetIconState",,block%
ENDPROC
  ^[ Log in to reply ]
 

Acorn Arcade forums: Programming: Select changes?