View Full Version : Quick (keyboard?) commands for text formatting, without WYSIWYG?
djr33
08-26-2012, 08:20 AM
I've long since left the evils of WYSIWYG behind. But sometimes I still miss one aspect of it: keyboard commands for bold, italics, underline, etc.
This is rarely a major concern, but when I find yourself doing word processing in HTML, I often wish I had WYSIWYG again. But if I did that, it would generate a bunch of nonsense code I'd need to remove anyway.
Today I found myself in such a situation so I actually started to use the quick reply box here, with it's WYSIWYG controls to quickly make sections of the text bold. (Writing [B] repeatedly can get old, after doing it dozens of times.) Then I used a text editor to find and replace that text with <strong>.
(There's also the annoyance of needing to use <strong> and <em> instead of <b> and <i>, which is perfectly fine except that, again after typing it dozens of times, it gets tiring.)
So ranting aside, does anyone have any good ideas for this?
What I would love would be a text-based HTML editor that allowed/included keyboard shortcuts like ctrl+B for bold and it would insert <strong> tags around the text. Considering that the best tag might vary, perhaps it should be something customizable.
Are there any programs like that? Any quick alternatives? (This doesn't come up very often, but when it does it's very slow for me at the moment, while I could do the same in MS Word in about 1/5 the time.)
jscheuer1
08-26-2012, 01:24 PM
EditPadPro has custom clip collections. They can be just clips or they can wrap highlighted text. No hot keys, but you can double click on them in a sidepanel to use them in the main editing pane.
NotePad++ has a plugin that's similar - Finger Text, that I find it a little harder to use, haven't quite figured out the easiest way. But it does have a sort of hot key type interface as I recall.
Other editors, perhaps. There might even be a third party util out there that allows for clips to be dragged anywhere (well into most text editors anyway) and that's 'always on top'.
djr33
08-26-2012, 09:23 PM
One further complication in my specific case is that I'm on a mac, so I don't think I can use the programs you suggested. (I love TextWrangler, but I can't find anything like that for it.)
Thanks for the ideas, though, and that should help a lot of people. Maybe I'll find something similar for mac as well-- it gives me a little hope that such things exist at all.
This only is an issue when I'm doing serious word processing. So I don't need it to be convenient to access or even available in my daily editor. I just need something that is efficient when I need to use it for a project. Otherwise I can just type out <em> or <strong> a few times as needed.
Maybe this would be a good idea for a script-- a basic WYSIWYG word processor for HTML that generates valid code. But limited specifically to basic word processing.
fKeBh1HtCmEJ
08-29-2012, 06:35 AM
There really isn't any program for that. You can utilize the copy/paste technique, wherein you put in notepad a list of common commands, and you just copy and paste them into your work.
bernie1227
08-29-2012, 09:55 AM
two things you can try;
1. wine for running windows programs on other OS's
2. custom keyboard shortucts
djr33
08-29-2012, 03:52 PM
Wine is for Linux, as far as I know. I don't think it's available for Mac. And there are some ways to run windows programs on a mac, but I'd prefer something native because every experience I've had with that has involved things running slowly and often crashing. (I also could use a PC if needed. But I'd just prefer to find something that works conveniently on my Mac.)
I've thought about custom keyboard shortcuts. Actually, I guess I could take this to a very deep (OS) level and create a new keyboard layout that would actually type these things out for me. alt+b = <strong>, alt+shift+b = </strong>, etc. I've recently tried playing with making new keyboard layouts for linguistics/language reasons, but that's not a bad idea for web design either... thanks for pointing me in that direction again. I'd thought of it and didn't find any custom commands options in Text Wrangler, but I guess I don't have to be limited by that program, do I...
Hey Daniel, you might want to look at Komodo Edit (http://www.activestate.com/komodo-edit). It runs on Mac/Win/Linux. It has decent autocompletion, and I'm (almost) positive you can define your own macros. I'll check when I get home.
djr33
08-30-2012, 02:14 AM
Alright, thanks. I'll check it out. Surprisingly, it's for Windows/Mac/Linux. Most programs aren't. I'm really happy with Text Wrangler for now, but if Komodo would make word processing in HTML a reasonable process, that will be a good tool to have too :)
making a macro in Komodo Edit
[this example uses version 7.0.2 for i86 Linux; recent versions for other OS's should be similar]
Tools > Macros > Start Recording
[do whatever: in this case, write <strong></strong> and then position cursor between tags]
Tools > Macros > Stop Recording
Tools > Macros > Save to Toolbox
From the toolbox sidebar, you can assign key combinations to your macros (like Ctrl+b, for example).
As much as I love macros, there are tons of better reasons to use Komodo. For example, if you have PHP installed on your system, Komodo can display function signatures (e.g., if you write in_array( and then pause, a tooltip will pop up that says "bool in_array ( mixed $needle , array $haystack [, bool $strict = FALSE ] ) Searches haystack for needle") and point out parse errors while you type.
djr33
08-30-2012, 04:07 AM
That sounds like a good option. It would be nice if it actually worked like a real word processor (but just as code rather than a preview) where you could actually select things and use ctrl+b, hit it again to remove the bold, etc. But maybe that's too much to ask for. (I actually doubt it would be all that difficult to write, though! Someone should do that...)
Those features do sound cool. I grew tired of Dreamweaver long ago (even after I had been using only the 'code view' for a long time), but one feature I miss from that is the popup help with functions (just the order of arguments!). Maybe I'll get addicted to Komodo as I use it.
Thinking about it, Text Wrangler actually isn't all that amazing-- I just love it because all of my other experiences with code editors have been so bad. It has FTP and direct editing of files on a site, it has decent and customizable syntax highlighting, it allows tabs to move entire blocks (multiple lines) of code, and it generally doesn't crash. It has a few more features than that, but those are my favorites anyway, and things often missing in other editors. Sounds like Komodo has all of that too, though, so we'll see.
I seem to remember trying to use Komodo a while ago and it not working-- maybe it wasn't available on Mac a couple years ago or something like that.
That sounds like a good option. It would be nice if it actually worked like a real word processor (but just as code rather than a preview) where you could actually select things and use ctrl+b, hit it again to remove the bold, etc. But maybe that's too much to ask for.I'm not sure how to code the "un-bold" type of things, but I bet it could be done. I'll have to experiment.
Thinking about it, Text Wrangler actually isn't all that amazing-- I just love it because all of my other experiences with code editors have been so bad...I think you may have hit on something, there: good == pleasant
jscheuer1
08-30-2012, 04:45 AM
I just found:
http://speckyboy.com/2011/06/14/10-free-desktop-applications-for-managing-your-code-snippets/
looks interesting.
djr33
08-30-2012, 05:07 AM
I think you may have hit on something, there: good == pleasant Indeed :)
And do let me know if you figure out any complicated macro tricks in Komodo. I don't need it at the moment (so don't spend too much of your time on it!) but it would be really nice to find a perfect solution for this at some point.
John, those do look interesting but from what I can tell they're just a convenient place to store code, not to immediately access it. For a library of functions, that would be great. But it wouldn't significantly improve typing speeds for <strong>, I don't think. In fact, it looks like you'd have to cut and paste, right? Or do some have a way to integrate with editors?
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.