Direct answer:: No.
Can it be made? Yes.
Into a single shortcut? Yes
What's needed? N++ PythonScript and HTML Tag plugins.
Why? We are going to use the HTML Tag's
Select Tag and Contents from a python script that will adjust the selection made by HTML Tag by moving the start to just after the first '>' and the end to just before the last '<'.
After installing the N++ PythonScript plugin create a new script with this code::
# Reduce selection to omit the outer most tags selected by the 'HTML Tag' plugin.
from Npp import *
def omit_tag( args ):
SelText = editor.getSelText()
orig_Start = editor.getSelectionStart()
new_Start = orig_Start + SelText.find(">")
orig_End = editor.getSelectionEnd()
new_End = orig_Start + SelText.rfind("<")
if new_Start > orig_Start and new_End < orig_End:
editor.setSel( new_Start + 1, new_End )
editor.callback( omit_tag, [SCINTILLANOTIFICATION.UPDATEUI] )
notepad.runMenuCommand("HTML Tag", "Select Tag and Contents")
After creating the script, use the PythonScript configuration dialog to add the script to the 'Menu Items' list (which will allow us to assign the shortcut). Restart, then use the Settings->Shortcut Mapper::Plugins dialog, add a Shift+Alt+T shoftcut to the new entry for the script you just created. Restart again to write out the new shortcut entry the N++ config.
So now (using your sample text), from the line where you wanted to click::
CTRL+T to jump to the other tag.
CTRL+Shift+T to select the whole tag block.
Shift+Alt+T to select the inner text.
If you attempt to select the 'content' portion of the block you'll notice the line endings are captured too. This could be seen as either a plus or minus depending on your viewpoint...
One recommendation, make use of
SCI_SWAPMAINANCHORCARET to allow you to adjust either end of your selection using the normal movement and selection modifiers. You can set it from the shortcut mapper on the Scintilla panel (near the bottom). I've set mine to CTRL+Shift. which works great, since when already modifying a selection Shift is usually already pressed.
Hopefully that helps. Have fun!