xiantez

SciTE Config - Syntax Color Question

9 posts in this topic

Hey Community,

I was changing around my color scheme manually for syntax highlighting. I really enjoy using a dark background color. However, this seems to be problematic because my blinking cursor is also very dark. Is there a setting in the ScITE config where I can manipulate the blinking cursor to be a different color like "white" so it is easy to spot when coding. The closest thing I found was "Caret Line Color", but this just changes the line highlight.  Your help is greatly appreciated!!

ScITE config.png

Share this post


Link to post
Share on other sites



not sure how to do what you asked, but if it helps, at the very bottom bar of the SciTE window frame it shows the position (line and column) of the cursor.

ex. li=31 co=74


if @error Then
	MsgBox(262192,"",@ComputerName&" slaps "&@UserName&" around a bit with a large trout!")
	EndIf

>Exit code: 0

REAL search results

"Yeah yeah yeah, patience. How long will that take?"  -Ed Gruberman

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

 


Although I would recommend ISN AutoIt Studio. Here's my config that will give you a nice pretty dark style. Right underneath my post is the workaround to change the caret color.

Edited by InunoTaishou

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

1 hour ago, InunoTaishou said:

Hey InunoTaishou,

Thanks for the advice.... I have never used the ISN AutoIt Studio, what are some of the key benefits of this application? Also, I grabbed your code for the theme.... I am not sure where I need to apply it though....

 

 

scripteditor_font=Consolas
scripteditor_size=10
scripteditor_bgcolour=0x1F1F1F
scripteditor_rowcolour=0x585858
scripteditor_marccolour=0xFFFFFF
scripteditor_highlightcolour=0x3C9BFF
treefont_font=Segoe UI
treefont_size=9
treefont_colour=0x000000
default_font=Segoe UI
default_font_size=9
AU3_DEFAULT_STYLE1=0xC8C8C8|0x1F1F1F|0|0|0
AU3_DEFAULT_STYLE2=0xC8C8C8|0x1F1F1F|0|0|0
AU3_COMMENT_STYLE1=0x23BC4C|0x1F1F1F|0|1|0
AU3_COMMENT_STYLE2=0x23BC4C|0x1F1F1F|0|0|0
AU3_COMMENTBLOCK_STYLE1=0x23BC4C|0x1F1F1F|0|1|0
AU3_COMMENTBLOCK_STYLE2=0x23BC4C|0x1F1F1F|0|0|0
AU3_NUM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ommend ISN AutoIt Studio. Here's my config that will give you a nice pretty dark style. Right underneath my post is the workaround to change the caret color.

 

Edited by xiantez

Share this post


Link to post
Share on other sites

It's the closest thing to an IDE for AutoIt that we have. Much more than just the basic Scite Editor.

Once you've got it installed, and you've ran ISN to set everything up first, there's a config.ini under D:\Users\Your Username\My Documents\ISN AutoIt Studio\Data\ You can put those values in the post in that config file. You can also edit more settings by going to File -> Settings (Under Script Editor is the colors)

As for the Macro, to change the color for the caret. Project -> Macros -> New Macro. Click the + button next to functions and make the trigger Open File. Click the + button next to Details and select Execute Command. Hit OK and use this command

SendMessage($SCE_EDITOR[_GUICtrlTab_GetCurFocus($hTab)], $SCI_SETCARETFORE, 0xFFFFFF, 0)

You can change 0xFFFFF to whatever color you want the caret to be. Save your macro and re-open your script to update the caret.

Until the updated ISN comes up you'll have to add the macro to each project, so just save the macro and import it when you start a new project.

1 person likes this

Share this post


Link to post
Share on other sites

Well I am using ISN AutoIt Studio now... it is really neat... however I still have the same issues.... Cannot figure out how to change the blinking cursor color to white, since I have a black background....

Share this post


Link to post
Share on other sites

The post right under where my config is (in the ISN autoit studio topic) tells you how to change the caret color (the blinking cursor is called the caret)

I also explained how to, step by step, add the macro to change the caret color in my last post in this topic.

2 hours ago, InunoTaishou said:

As for the Macro, to change the color for the caret. Project -> Macros -> New Macro. Click the + button next to functions and make the trigger Open File. Click the + button next to Details and select Execute Command. Hit OK and use this command

SendMessage($SCE_EDITOR[_GUICtrlTab_GetCurFocus($hTab)], $SCI_SETCARETFORE, 0xFFFFFF, 0)

You can change 0xFFFFF to whatever color you want the caret to be. Save your macro and re-open your script to update the caret.

Until the updated ISN comes up you'll have to add the macro to each project, so just save the macro and import it when you start a new project.

 

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

This color is not part of the SciTEConfig options but can be manually added by adding this line in SciTEUser.properties:

# Make caret white
caret.fore=#FFFFFF

Jos

Dup Threads merged.

Edited by Jos

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Oh ok...i apologize for the confusion.... I appreciate all your help!

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Similar Content

    • tremolux66
      By tremolux66
      I use a monospace font for editing AutoIt scripts in SciTE (currently, CourierNew 9pt). Regardless of what font size I set in the configuration, when I start SciTE to resume editing the script text is one size smaller than I specified. When I type Ctrl+<numpad-slash> the text changes to the desired size. The same is true of the output pane, and I have to reset the size for both areas every time I start SciTE.
      IIRC, I've made few other changes to the configuration (e.g., changed the search highlight color and disabled Tidy), so this behavior seems odd. About SciTE says it's version 3.6.0 (Aug. 4, 2015).
      Any idea how to fix this?
    • user4157124
      By user4157124
      As they're opinion-based to some degree; how are AutoIt's best practices decided and do suggestions get considered?
      Some suggestions :
      For...To...Step...Next -loop variable-naming like $iN ($i1, $i2, etc.) : conforms to recommended naming convention, identifies level (albeit inverted to ExitLoop and ContinueLoop's convention) and enables SciTE selection-highlighting (requires minimum of 3 characters). Minimize logic in global scope, separate data & settings from logic, use of vertical space, project organization (folder structure, resource- and include file management). Example (loop variable-naming, minimizing logic in global scope and separation of settings from logic) :
      #include <Array.au3> Global Enum $RANDOM_RETURNFLOAT, _ $RANDOM_RETURNINTEGER Global Enum $EXITCODE_NONE Global Const $g_sChar0 = '-' Global Const $g_sChar1 = '+' Global Const $g_iAmountX = 10 Global Const $g_iAmountY = $g_iAmountX Main() Func Main() Local $aArray[$g_iAmountY][$g_iAmountX] For $i1 = 0 To $g_iAmountY - 1 For $i2 = 0 To $g_iAmountX - 1 $aArray[$i1][$i2] = Random(0, 1, $RANDOM_RETURNINTEGER) ? $g_sChar1 : $g_sChar0 Next Next _ArrayDisplay($aArray) Exit $EXITCODE_NONE EndFunc Example (project organization) :
      + project_folder + bak [backup files] + bin [distributed binaries and dependencies] + inc [non-standard include files] + res [resource files (icons, file+install files, etc.)] + usr [configuration files, databases, etc.] - script.au3 - script.exe Example (use of vertical space) :
      Func _DigitalRoot($iNum) Local $sNum = '' Local $aNum While $iNum > 9 $sNum = String($iNum) $aNum = StringSplit($sNum, '') $iNum = 0 For $i1 = 1 To $aNum[0] $iNum += Int($aNum[$i1]) Next WEnd Return $iNum EndFunc
    • wimhek
      By wimhek
      LS
      Is it possible to open file(s) in scite in read only mode ?
      If so, How ?
       
      Thnx
       
    • AndreyS
      By AndreyS
      Tell me, please, how to set / change the cursor over RichEdit (created with _GUICtrlRichEdit_Create)?
    • Hoth2001
      By Hoth2001
      I installed AutoIt to my computer 3 days ago...and have invested the last 3 days learning how to use it.
      As learned in the tutorials, whenever opening I new file in Scite editor I'd immediatley save the file
      I left the Scite Editor open for the past 3 consecutive days on my laptop
       
      No problem
       
      Today I closed Autoit for the first time, restarted my computer, and opened up the Scite Editor
      Now whenever I try to save a file I am prevented from doing so because I apparently don't have permission!?  
      And whenever I try to run any of the programs I've created over the past 3 days now I keep getting annoying popup notifications before I run them
       
      Problem
       
      To go around the issue, I copied a program originally saved in the AUtoIt folder to another folder (since I was barred from saving it in it's original AutoIt location)
      NOw when I run the code the mouse coordiantes are all off
      and I still get that pesky notification whenever I try to run a program
       
      Big Problem!!!
      Anyone have any clue why I'm going through this BS?
       
      1. I checked my User settings and YES I am the administrator on this cpu
      2. I tried to de-select the "read only" attribute for the AutoIt folder (everytime after doing this successfully the folder immediately and automatically reverts back to "read only")
       
      Any help would be MOST appreciated. I've attached screen shots of the annoying bus I keep getting