home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   alt.comp.os.windows-11      Steaming pile of horseshit Windows 11      4,969 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 4,574 of 4,969   
   Maria Sophia to Maria Sophia   
   Re: PSA: HTML fragment mode interaction    
   10 Feb 26 07:32:36   
   
   XPost: alt.comp.os.windows-10, alt.comp.microsoft.windows   
   From: mariasophia@comprehension.com   
      
   Maria Sophia wrote:   
   > The workaround I've come up with is surprisingly simple:   
   > a. Insert an extraneous leading blank line at the top of the document   
   > b. Now when you press Ctrl+A, the selection works as expected   
   > c. Copy (Ctrl+C) or Cut (Ctrl+V) the selected text, as desired   
   > d. Then delete the extraneous leading blank line   
      
   Ooops...   
   I had meant "Ctrl+X" above in item (c).   
   Working as a team, can you let me know if you can reproduce this easily?   
      
   1. Open Microsoft Edge (or any Chromium-based web browser).   
   2. Go to any web page, for example:   
      Win+R > msedge https://en.wikipedia.org/wiki/Quotation_mark   
   3. Select any text on the page (e.g., Ctrl+A)   
   4. Press Ctrl+C to copy whatever text you had selected   
   5. Open Notepad++   
   6. Press Ctrl+V to paste the text   
   7. Now press Ctrl+A   
   Huh? You will see the selection flash, but nothing is selected.   
      
   This is the "HTML fragment mode" issue described above.   
      
   Apparently, this artifact happens because Chromium puts hidden HTML on the   
   clipboard, and Notepad++ reacts to that by entering a special mode where   
   Ctrl+A and Ctrl+X do not work.   
      
   Please try it because maybe it's just me, but I've been battling this   
   artifact for a long time because it's completely hidden in a hex editor.   
      
   One false trail that sent me off the scent was that I had originally   
   suspected this problem was related to the BOM indicator in the   
   bottom-right corner of Notepad++. It is not. The BOM only tells us what   
   encoding Notepad++ will use when saving the file. It does not affect how   
   pasted text behaves.   
      
   The HTML fragment mode problem happens even when:   
   a. the file is brand new   
   b. the file has never been saved   
   c. the encoding is "ANSI" or "UTF-8" with no BOM   
   d. there is no BOM in the file at all   
      
   This artifact is caused entirely by the clipboard data format that Chromium   
   applications place on the Windows clipboard. Notepad++ sees the hidden HTML   
   version and enters HTML fragment mode. The BOM is not involved in any way.   
      
   I've always said I never quite understood all this character set stuff...   
   --   
   The nice thing about Usenet is you get good ideas from everyone.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca