Posix vs. Windows

Mehrdad wfunction at hotmail.com
Fri May 18 17:39:20 PDT 2012


On Friday, 18 May 2012 at 23:50:18 UTC, H. S. Teoh wrote:
>> Was it actually that slow?
>
> Anything that has a GUI is unacceptably slow over a remote 
> connection, last time I checked. I'm not talking about 
> connecting over a  local network, which doesn't really count, 
> but a connection over the internet.


Uhm, no.

The *slowest* GUI's I've seen are -- by far -- SSH-based. (e.g. 
remote Emacs -- even on a local network -- is horrible.)

I've _personally_ used National Instruments's tools over cable 
internet (if you've used them, you know they're certainly *not* 
less GUI-intensive than an IDE lol), and they're completely 
usable. Not /fast/, mind you -- but completely acceptable.

And no, my cable wasn't fantastic either.
And yes, it was plain old Remote Desktop.
Also, the other side's server was kinda slow too.

You should definitely try it. :P




> Strange, last I checked, global variables aren't a good coding 
> practice. :-) Renaming local variables is a trivial 
> search-n-replace.

lol ok you got me there


> But you're right that certain renamings, like a member function 
> name that may be overloaded across a large number of classes, 
> could potentially be very painful.

Yeah, imagine trying to name a method named "getValue()" to 
something else (probably because you realized that's not a great 
name :P).

A HUGE time waster without refactoring tools, and last time I 
checked, no text-based tool did it.


> Though what I'd really like in that case is a syntax-tree aware 
> text editor.


100% agree, I've been looking for them too. But they don't exist. 
And practically speaking, without project management (in which 
case they'd be half-baked IDEs), the *can't* exist...


> Or a nice console-based IDE that isn't dependent upon a GUI.
,
I'd probably use them too, but they don't exist AFAIK. :(



> "Intuitive" text editors are ultimately also limited by their 
> intuitiveness, because what most people think of as "intuitive" 
> is "what I type appears on the screen" and "I don't have to 
> memorize obscure key sequences to get stuff done". What you 
> really need are _logical_ operations, like "navigate to the 
> word 'void'", "go down 3 paragraphs", "go to the start of this 
> block", "replace text up to the next matching delimiter", 
> "select the function body", "line-wrap the selected text", etc..





> They aren't real editors, no, but a lot people seem to think 
> they are.

lol. Those people probably haven't used Linux either. :P


> I'm not talking about having to click through 5 menus and type 
> in a macro definition, bind it to some keystroke, and then run 
> it afterwards. I'm talking about things like "search for this 
> regex and replace it with that pattern, now do this again to 
> the next 25 occurrences of the search term" -- ON THE FLY.

Oh, I misunderstood then. In that case, you don't even need an 
external tool...

Ctrl-H: Brings up Replace dialog.
Alt-E: Check the "Regex" box.
Alt-P: Type in the regex.
<types regex>
Alt-R: However many times you want, to replace the next instance.

Though I'd question what you were doing if it were 25 times. Most 
likely you want to do it within a certain range of the document, 
in which case you can highlight that portion of the text (with 
the keyboard or the mouse, both are easy :P), and just tell your 
editor/IDE to replace only that portion.

Both are a piece of cake, and neither needs an external tool.




> I don't care to waste time defining a whole named macro just 
> for this one occasion. I want to, in essence, write 1-line code 
> to transform the current selection, right now.

Yes, writing 1-line code is definitely easier in *nix-based tools 
(since they're text based, obviously), but if you have any other 
examples of actual tasks you do regularly, let me know -- I'm 
sure there's a way to do them with VS/Eclipse that isn't much 
different in terms of the amount of work/payoff.

>> Well, it does what you're saying.
>> In a more powerful way than you're saying. :P
>
> Then please enlighten me with an example. :-)

They give you access to the *entire IDE* and *all APIs 
whatsoever*, so "give me an example" results in "pretty much 
anything you want" -- minus the syntax tree, unfortunately (not 
sure why).

But if you need an example...

I've made a macro to look for all of my C++ include and library 
directories, and switch them from Visual Studio to Windows WDK 
(for various reasns).
Oh, and to detect where the WDK is, I read the registry keys 
inside the macro, find the directories, etc.. Easy. And *none* of 
the pain with escaping quotes or whatnot, since it's an actual 
*language* (VB.NET, which has nothing to do with VB6, btw -- just 
C# in a different syntax), not a Bash script.

Oh, and it supports different versions of the WDK.

All in about ~150-200 lines of VB.NET code, and I've used it a 
few dozens of times now. Saved my fingers from all the typing I'd 
otherwise have to do to change a gazillion project settings. And 
I don't have to interface with any text lol.

If you were to do this with some text-based tool, it'd be next to 
impossible IMO, since you'd have to edit XML settings, and keep 
track of all the repetitions (e.g. something might appear under a 
Debug node but not a Release node, etc.).


> By which I mean VI vs. EMACS, of course. ;-)


Ah lol.

I hate both. XD


More information about the Digitalmars-d mailing list