« first day (471 days earlier)      last day (2709 days later) » 

12:01 AM
RELOAD!
[ShearOfDoom/CactusReborn] 5 commits. 140 additions. 29 deletions.
[Zomis/Duga] 1 issue comment.
 
 
13 hours later…
12:50 PM
I thought you guys were responsible for this : plugins.jetbrains.com/plugin/7184?pr=idea but you're probably not ;)
 
 
1 hour later…
2:13 PM
@Marc-Andre I don't think so. I've never heard of it.
I don't know of any Richard Freedman here.
 
 
8 hours later…
10:23 PM
I'm almost too scared to continue.
How in the world am I to duplicate On Error Resume Next behavior?
 
eeek
I don't think it can translate 1:1
 
Me either.
You'll have to proofread it.
I'm doing the modIndentRoutine file right now.
 
eh, even if I end up doing it, I'll have it proof-read anyway
most of the important code is just calls to the VBE API though
what worries me is the options handling
 
Now, I cannot use C#6, right?
I want to use string interpolation, but string.format will do.
 
not if you want it to compile with RD
 
10:26 PM
LOL, OK.
 
SmartIndenter uses registry keys to store options
 
Either that or + signs.
Yeah, I'm already having trouble with them.
Let's use an XML file.
 
we need to decide that
I think we should put them alongside the RD other options
 
That is an XML file.
Isn't it?
 
yeah
I think the first thing to do is determine what registry keys SmartIndenter is using for options, and to create the corresponding RD settings
 
10:30 PM
This feels like jumping off a cliff without knowing if there is a safety net at the bottom.
 
there isn't ;-)
 
It feels like the time I was going through an intersection, and I didn't have a stop sign.
The other side did, but they didn't stop. I stopped, then they started backing up, and got in an accident.
 
first things first: dependencies
the VB6 code has a tight dependency on the registry. we need to cut that
 
NVM, mistake on my side.
One other thing - it has a key hook.
We might as well make that global.
 
Preserve keeps the contents of the array intact. ReDim alone wipes it out
 
10:35 PM
Yeah, I'll just use a List and Add().
 
oh yes, that bit me back in the day I worked on vba code..
I'd also do a proofread if you want me to :)
 
Sure.
 
until then I'll try to get my C# up to par again.
 
What in the world is a With block?
 
using
 
10:38 PM
sort of
 
actually no..
 
With pauUndo(piUndoCount)
    Set .oMod = modCode
    .sName = sName
    .lStartLine = iStartLine
    .lEndLine = iEndline
    ReDim .asIndented(0 To iEndline - iStartLine)
    ReDim .asOriginal(0 To iEndline - iStartLine)
End With
 
it shortcuts what's before .
 
Oh, I see.
 
it's the lazy coder's way of avoiding to type
 
10:38 PM
Yeah, I get it now.
 
so
var foo = pauUndo(piUndoCount)
and then
 
it's basically a local implied this
 
foo.oMod = modCode
and so on
@Vogel612 there's more to it
 
@Mat'sMug is it actually stored or is it reinvoked?
 
it's stored. the With block holds the reference
what's why I said "sort of" when you said "using"
 
10:40 PM
and you can nest them, right?
 
if you're the devil incarnate, yes
 
With foo
    .bar()
    With .quux()
       .callCthulu()
    End With
End With
hmm... that's just me, right?
 
what's that?
 
I have no idea
the dark background is SO Dark Chat +
 
Catch me doing this again...
 
10:42 PM
ah
 
but I don't know where the syntax highlight comes from
hmm... it vanished..
 
well I had quite a bit of fun writing resolver code that correctly handled nested withs; wouldn't surprise me that the syntax highlighter doesn't like it
 
Wow, I have no idea what I'm doing.
Set oCM = modCode
That is an assignment, right?
 
of an object variable, yes
 
hmm.. it only happens for new messages.
 
10:44 PM
oCM is declared earlier as an Object.
This is the first reference, so I change it to this: object objCodeModule = codeModule;
 
VB requires you to use a special assignment for refernce types.
 
Now, codeModule is a DI'ed CodeModule.
And the next statement is this: iMembers = oCM.Members.Count
 
and why can't you work off codeModule?
 
I have no idea.
 
ugh. full-on Hungarian FTW
 
10:45 PM
ohh cool, hungarian notation
 
But, an Object has no idea about a .Members whatever.
The best part? Those aren't really ints!
 
yea.. dynamically invoked languages
 
They are - guess what? - longs!
 
VB6 Integer == C# short
 
WT*$#?
 
10:46 PM
VB6 Long == C# int
 
What kind of imbecile designed this language?
 
actually @Hosch250 VB just is that old
 
Here come the psychopathic maintainers! :P
 
back then Integer meant Int16
 
OK. re-types longs to ints
 
10:47 PM
#define long int
 
lol
 
Fat chance.
 
#define int short
 
This was done wrong once, it is going to be done right the second time, then posted on CR.
 
Hey Mat did you hear back from that person with the two open PRs?
 
10:49 PM
@Hosch250 I think it could be more productive if you worked on the indenter settings
@Vogel612 nope
 
@Mat'sMug Probably.
 
... did I scare them away?
 
But the trouble is, I can't even read those files.
Don't worry, I'm actually making progress.
 
lol
 
whenever you see GetSetting, there's a registry key involved. They're sprinkled all over
SaveSetting too
 
10:51 PM
probably you need to translate it over and then refactor the hell out of it
more literally than I'd like.
 
That's what I'm doing.
 
[rubberduck-vba/Rubberduck] INOPIAE pushed commit fc54a18a to next: Replaced "Menu Bar" by index number of the control bar so it should work on all langugae installations
Merge pull request #779 from INOPIAE/#778

Replaced "Menu Bar" by index number of the control bar so it should w…
 
"Menu Bar" is index 1 on all locales
 
on a completely unrelated note.. I opened a PR at libgit2sharp 12 days ago, and haven't heard back from them. But the issue I opened was replied to and discussed within hours.
@Mat'sMug hmm.. but nothing guarantees that the Strings work for other locales.
 
well, the PR only had that changed, so.. merged. I'd have done that anyway
 
10:53 PM
Is For i = 1 To iMembers like for (int i = 1; i < iMembers; i++) or for (int i = 1; i <= iMembers; i++)?
 
hmm.. I'll place cleanup for 778 on my list.
the latter IIRC
remember 1-based collection access
 
Wow.
Oh, yeah.
 
which means that you need to iterate up to length including to get all the items.
 
VB.NET has And == & and AndAlso == &&. How does this work in VB6?
 
it doesn't
there's no short-circuiting operator in VB6
and And == & is falsey
 
10:56 PM
isn't & the binary one?
 
yes
 
OK...
 
but in VBA, whether "And" is a logical or a bitwise operator depends on ...context
 
I guess I'll use & for now.
 
, right?
 
10:57 PM
I'll leave a todo.
 
make that an XXX as per oracle guidelines :D
 
@Hosch250 use "&" when "And" is bitwise; use "&&" when "And" is logical
 
OK, I guess it is logical.
 
the fact that C#'s && short-circuits will not be a breaking change.
it would be different if VB6's logical operator short-circuited, but not C#'s
 
@Mat'sMug actually it could be if you invoke a method with side-effects.
 
11:00 PM
@Vogel612 yeah, ..you're right... but nobody does that, right?
 
[Hosch250/Rubberduck] Hosch250 pushed commit 7c8435fa to Indentation: I have no idea what I did...
2
 
(bangs head on desk)
2
 
Take a peek.
 
problem one:
SmartIndenter/CSharp6/modIndentRoutine.cs
 
I initially created it that, but then I changed the name.
That is VS's fault.
 
11:03 PM
haha
 
namespace Rubberduck.SmartIndenter.CSharp6
 
I just kept the same file structure. We can redo it later, I guess.
I bail out.
 
eh, not a biggie. Ctrl+R,R to the rescue
 
It'll be faster for you to do it.
 
11:05 PM
I think [next] should be merged into that branch first
 
I'll help unit test it and stuff once you get it up.
Probably.
And the methods are absolutely huge.
 
have you seen Smart Indenter's options?
 
No.
I'll install it now.
 
there's a shitload of 'em
as I said, if we first address the options, we'll have a good start.
 
Yep.
So, basically, we need to parse the XML file and DI them.
 
11:08 PM
because with that many options, everything is interfering with how the code works
we need to implement a SmartIndenterSettings serializable class
and then create a control for the RD settings dialog
 
You know, if we could simply get the hook in, it would be faster to write it from scratch.
 
then the SmartIndenter feature will use an IGeneralConfigService
what hook?
 
He uses a key hook to capture key presses.
 
yes, I want to inspire from that to eventually implement our own keyboard shortcuts :)
but we aren't rewriting that add-in from scratch
we're rewriting it in C#, with all of the functionality
 
Check the modVBEOnKey.bas file.
 
11:11 PM
it has to have the name "Smart Indenter", and live up to it
 
What happens when we add more features?
 
we can do that
but before we add features... we need the existing ones implemented ;-)
anyway, gtg / bbl
 
See you.
 

« first day (471 days earlier)      last day (2709 days later) »