Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 11:10 01 Aug 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Quick One for TassyJim.

     Page 1 of 2    
Author Message
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1667
Posted: 04:12am 22 Feb 2018
Copy link to clipboard 
Print this post

Printing code in colour?

Just printed 13 pages for a school project & it came out B/W.

Didn't actually check my settings, but can MMEdit print colour?

If not is there an easy way to take TBS formatted code to another application & print in colour from there?


Thanks

Phil.
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9610
Posted: 04:21am 22 Feb 2018
Copy link to clipboard 
Print this post

I'm not Jim, but FILE/SAVE AS RTF works for me.
This outputs a colour RTF file, which I then save as a PDF - job done.
Smoke makes things work. When the smoke gets out, it stops!
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 05:37am 22 Feb 2018
Copy link to clipboard 
Print this post

Grogster has it spot on.

Printing colour was a pain so I let some other program do it...

Jim
VK7JH
MMedit
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 08:21am 23 Feb 2018
Copy link to clipboard 
Print this post

Hi,
I wanted to know this to, but I must be missing something. Didn't find an option to save as an RTF file so I replaced the .bas with .rtf but it still only opened as a normal B&W file in a word processor.

Chopperp
ChopperP
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9610
Posted: 08:41am 23 Feb 2018
Copy link to clipboard 
Print this post

Click FILE menu at the top left of the window, then moved down to 'Save as RTF', and left-click. Follow your nose from there.
Smoke makes things work. When the smoke gets out, it stops!
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 08:47am 23 Feb 2018
Copy link to clipboard 
Print this post

Can't see 'Save as RTF'. Ill up date MMEdit & see if it is there
Thanks
ChopperP
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 08:48am 23 Feb 2018
Copy link to clipboard 
Print this post

OK, that worked. Thanks
ChopperP
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9610
Posted: 08:52am 23 Feb 2018
Copy link to clipboard 
Print this post

I was about to suggest the latest version of MMEDIT, but you thought ahead of me.
Smoke makes things work. When the smoke gets out, it stops!
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 09:07am 23 Feb 2018
Copy link to clipboard 
Print this post

Another question..

Anyway of printing the line numbers?

Thanks
ChopperP
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9610
Posted: 09:56am 23 Feb 2018
Copy link to clipboard 
Print this post

Pass.

Jim?
Smoke makes things work. When the smoke gets out, it stops!
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 08:31pm 23 Feb 2018
Copy link to clipboard 
Print this post

I did experiment with printing line numbers.
I can't remember why I gave up, I think it got too unreliable.




Getting the line-number colours correct is not difficult but the line-wrapping really stuffs up the display.

I don't want to do my own line-wrapping, it would only add more problems.

JimEdited by TassyJim 2018-02-25
VK7JH
MMedit
 
Phil23
Guru

Joined: 27/03/2016
Location: Australia
Posts: 1667
Posted: 10:11pm 23 Feb 2018
Copy link to clipboard 
Print this post

Had a little play, notice also that RTF retains the original case of the code as typed.

[Quote]
String
Vs
String

Other thought that came to mind was what can be done from NotePad++.

I did play around with a User Defined Language as metioned here.

Didn't ever try printing.
The language mostly works Like MMedit in it's colour coding but I never got it 100% right.

One big bonus though is that I did get it to the stage where it would let you list Subs & Functions in a box; really use for jumping around code.

Npp should have a line numbering plug-in, think I played with that & noticed there's an RTF add-on language as well.

Phil.

 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 11:14pm 23 Feb 2018
Copy link to clipboard 
Print this post

Phil,
If you want to print with the keywords in your chosen case, you need to select "Save Keyword CASE" in the Program menu first.
That will permanently alter your file with the format that you chose in Preferences.
It doesn't affect any new typing so you have to run it as required.

The process is too slow to automatically run too often.

Jim

VK7JH
MMedit
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 11:40pm 23 Feb 2018
Copy link to clipboard 
Print this post

>I did experiment with printing line numbers.
>I can't remember why I gave up, I think it got too unreliable.

OK
Thanks Jim
ChopperP
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 11:45pm 23 Feb 2018
Copy link to clipboard 
Print this post

  TassyJim said   I did experiment with printing line numbers.
I can't remember why I gave up, I think it got too unreliable.

Found the Quote button

Thanks Jim

ChopperP
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 12:08am 24 Feb 2018
Copy link to clipboard 
Print this post

For Jim again

For the CMM V4.5. Noticed that the Alpha-Numeric pin numbers (A0 etc) don't come up in red as do the normal pin numbers.
No real issue.

setpin 9, ain 'analog I/P for solar panel
setpin A0, ain 'Analog I/P for switches
setpin 10, inth, Rain_Gauge 'Rain Gauge Interrupt
setpin 20, INTL, Sw_Press 'Switch press detect
setpin D9, DIN 'Grey Water ON switch
lcd init D2,D3,D4,D5,D6,D7

Chopperp
ChopperP
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 12:42am 24 Feb 2018
Copy link to clipboard 
Print this post

Just realised that Jim has all numbers come up in Red not only pin numbers so not really applicable to alpha-numeric pin numbers, though that would be good

ChopperP
ChopperP
 
Azure

Guru

Joined: 09/11/2017
Location: Australia
Posts: 446
Posted: 12:45am 24 Feb 2018
Copy link to clipboard 
Print this post

  Chopperp said  
Found the Quote button


You also need to make sure the end quote or is after the quote or code you want to mark otherwise it wont do what you wanted.
 
Chopperp

Guru

Joined: 03/01/2018
Location: Australia
Posts: 1097
Posted: 12:56am 24 Feb 2018
Copy link to clipboard 
Print this post

  Azure said  
  Chopperp said  
Found the Quote button

You also need to make sure the end quote
or is after the quote or code you want to mark otherwise it wont do what you wanted.


I thought I was doing something wrong

Thanks
Chopperp
ChopperP
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 01:51am 24 Feb 2018
Copy link to clipboard 
Print this post

If it starts with a digit, &H (hex), &B (binary) or &O (octal), it's a number

  Quote  
27BDFFC0
&HAFB1001C
&B01000011000010000000010001001111
&OA6410015
AFB1001C

anything else is a 'word'

It does cause a few issues with CFUNCTIONs

I will add the option to print line numbers to RTF, but you will have to live with any consequences. My main objection is, you loose the ability to copy and paste back into MMEdit because of the pesky line numbers.

JimEdited by TassyJim 2018-02-25
VK7JH
MMedit
 
     Page 1 of 2    
Print this page
The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025