BBC BASIC for Windows
« Custom text background SOLVED!! Sorta.. »

Welcome Guest. Please Login or Register.
Apr 5th, 2018, 11:06pm



ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018.
Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.

If you require a dump of the post on your message board, please come to the support board and request it.


Thank you Conforums members.

BBC BASIC for Windows Resources
Online BBC BASIC for Windows documentation
BBC BASIC for Windows Beginners' Tutorial
BBC BASIC Home Page
BBC BASIC on Rosetta Code
BBC BASIC discussion group
BBC BASIC for Windows Programmers' Reference

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Custom text background SOLVED!! Sorta..  (Read 244 times)
michael
Senior Member
ImageImageImageImage


member is offline

Avatar




PM


Posts: 335
smiley Custom text background SOLVED!! Sorta..
« Thread started on: Mar 19th, 2016, 03:55am »

**** see link for my final custom solution****

http://bb4w.conforums.com/index.cgi?board=graphics&action=display&num=1458438004

********************************************
This is for information purposes only. I had to figure out a bit more about the differences between complete background and foreground controls and this wasn't the total solution I wanted.

The original program shows the problem, and with the examples I couldn't figure how the custom R,G,B settings would be shared with the background..

The Problem
Code:
  REM SET MODE TO 8 USING VDU (
      VDU 22,8
      REM SET LINE THICKNESS TO 3
      VDU 23,23,3|
      REM OFF
      GCOL 1
      COLOUR 1,175,165,150
      FILL 100,100
      COLOUR 157
      INPUT TAB(0,5) "Enter Your Information  " A$
      PRINTTAB(0,6);A$
      (mou)
      WAIT 0 : REM just wait, nothing to do !
      GOTO (mou)



 

And here is the solution: Thanks to Richard
Code:
COLOUR 1,175,165,150 : Set palette color 1 to RGB triplet
 COLOUR 128+1 : REM Set text background to palette color 1
 CLS
 INPUT TAB(0,5) "Enter Your Information: " A$
 PRINTTAB(0,6);A$
 

And his other sample given
Code:
 MODE 8
 COLOUR 1,175,165,150 : Set palette color 1 to RGB triplet
 GCOL 0 : REM Set graphics foreground to palette color 0
 GCOL 128+1 : REM Set graphics background to palette color 1
 VDU 5 : REM Treat text as graphics (transparent background)
 CLG
 MOVE 0,800
 PRINT "Hello world!"
 
« Last Edit: Mar 21st, 2016, 12:08am by michael » User IP Logged

I like making program generators and like reinventing the wheel
Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

| |

This forum powered for FREE by Conforums ©
Terms of Service | Privacy Policy | Conforums Support | Parental Controls