mirror of
				https://github.com/notepad-plus-plus/notepad-plus-plus.git
				synced 2025-11-04 05:23:56 +01:00 
			
		
		
		
	Skip auto-complete of tags within HTML script
Closes #2282 Closes #2284
This commit is contained in:
		
							parent
							
								
									eddafe55e8
								
							
						
					
					
						commit
						10c6dc0174
					
				@ -370,6 +370,14 @@ bool AutoCompletion::showFunctionComplete()
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
void AutoCompletion::getCloseTag(char *closeTag, size_t closeTagSize, size_t caretPos, bool isHTML)
 | 
					void AutoCompletion::getCloseTag(char *closeTag, size_t closeTagSize, size_t caretPos, bool isHTML)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 | 
						if (isHTML)
 | 
				
			||||||
 | 
						{
 | 
				
			||||||
 | 
							// Skip if caretPos is within any scripting language
 | 
				
			||||||
 | 
							int style = static_cast<int>(_pEditView->execute(SCI_GETSTYLEAT, caretPos));
 | 
				
			||||||
 | 
							if (style >= SCE_HJ_START)
 | 
				
			||||||
 | 
								return;
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	char prev = static_cast<char>(_pEditView->execute(SCI_GETCHARAT, caretPos - 2));
 | 
						char prev = static_cast<char>(_pEditView->execute(SCI_GETCHARAT, caretPos - 2));
 | 
				
			||||||
	char prevprev = static_cast<char>(_pEditView->execute(SCI_GETCHARAT, caretPos - 3));
 | 
						char prevprev = static_cast<char>(_pEditView->execute(SCI_GETCHARAT, caretPos - 3));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user