Jump to content

Search the Community

Showing results for tags 'EdgingSelection.LUA'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • General
    • Announcements and Site News
    • Administration
  • AutoIt v3
    • AutoIt Help and Support
    • AutoIt Technical Discussion
    • AutoIt Example Scripts
  • Scripting and Development
    • Developer General Discussion
    • Language Specific Discussion
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Categories

  • AutoIt Team
    • Beta
    • MVP
  • AutoIt
    • Automation
    • Databases and web connections
    • Data compression
    • Encryption and hash
    • Games
    • GUI Additions
    • Hardware
    • Information gathering
    • Internet protocol suite
    • Maths
    • Media
    • PDF
    • Security
    • Social Media and other Website API
    • Windows
  • Scripting and Development
  • IT Administration
    • Operating System Deployment
    • Windows Client
    • Windows Server
    • Office

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Location


WWW


Interests

Found 1 result

  1. Hi, i've made a LUA-script to use in SciTE for more comfort. Edge selected text with paired chars or set an empty pair on hit this char. Paired chars are: " ", ' ', ( ), { }, [ ] * Set edging always in multiple selected lines or in block selected areas (i.e. from line 3 to 8 in columns 20 to 30). * If caret position are left from selection hit the opening char, on position at the end hit the closing char. * It also works without selection, so you got empty pairs. The opening char must hit! (like AutoCloseBraces.lua). Hit closing char without selection inserts only this char. * ! If you want to set empty pairs on multiple lines, you must select 0 columns (hit SHIFT+ALT + n-times DOWN) and the closing char must hit. Downward selection is required for this. NOTE: * If you always use an script like 'AutoCloseBraces.lua', you must disable it. * The paired mode is disabled on using OVERWRITE in editor. * Keycodes for english and german keyboard layout implemented. Set your language in variable 'lang'. For other languages add own entries in table 'tCode'. To get right values uncomment the 'print'-line in function 'HitKey', hit the keys with pairing chars and read values from console. All entries('SHIFT', 'RAW', 'CTRL_ALT') must created, to avoid errors. If somewhere add entries for other languages it would nice to post it here for sharing. The value for INSERT-key is hardcoded with keycode '45' (hope is the same on all keyboard layouts) . Edit 2011-10-30: * Add functionality to exclude file-types from this behavior (i.e 'cpp') To exclude some file-types from this function, needs entry for every file-type that should excluded in 'SciTEUser.properties': 'NoPairs.ext=1' (.ext with lower chars!). To use this script, copy it in path '..\Scite\LUA\' Now make a new entry in SciTEStartup.lua : 'LoadLuaFile("EdgingSelection.lua")'. Reload StartUpScript (or restart SciTE to take effect). If you always use an script like 'AutoCloseBraces.lua', it's required to disable this, because the edging script has this funtion too. Your SciTEStartup.lua should look like this: And here the LUA script 'EdgingSelection.lua': (Current version v 1.4) Some pictures, how to use: - selection 0-columns, n-lines (SHIFT+ALT+ n-times DOWN) - than hit closing char - block selection - quote as string in every line on hit one time: " - select list of variables - cursor is left, hit opening brace (pooh, full editor has crashed all the text, i hope i've all correct restored) EdgingSelection1.4.lua.zip
×
×
  • Create New...