You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's an add-in for the VBA IDE, the glorious *Visual Basic Editor* (VBE) - which hasn't seen an update in this century, but that's still in use everywhere around the world. Rubberduck wants to give its users access to features you would find in the VBE if it had kept up with the features of Visual Studio and other IDE's in the past, oh, *decade* or so.
22
-
23
-
Rubberduck wants to help its users write better, cleaner, maintainable code. The many **code inspections** and **refactoring tools** help harmlessly making changes to the code, and **unit testing** helps writing a *safety net* that makes it easy to know exactly what broke when you made that *small little harmless modification*.
24
-
25
-
Rubberduck wants to bring VBA into the 21st century, and wants to see more open-source VBA repositories on [GitHub](https://github.com/) - VBA code and **source control** don't traditionally exactly work hand in hand; unless you've automated it, exporting each module one by one to your local repository, fetching the remote changes, re-importing every module one by one back into the project, ...is *a little bit* tedious. Rubberduck integrates Git into the IDE, and handles all the file handling behind the scenes - a bit like Visual Studio's *Team Explorer*.
26
-
27
-
---
28
-
29
-
If you're learning VBA, Rubberduck can help you avoid a few common beginner mistakes, and can probably show you a trick or two - even if you're only ever writing *macros*. If you're a more advanced programmer, you will appreciate the richness of [Rubberduck's feature set](https://github.com/retailcoder/Rubberduck/wiki/Features). See the [Installing](https://github.com/rubberduck-vba/Rubberduck/wiki/Installing) wiki page.
30
-
31
-
If you're a C# developer looking for a fun project to contribute to, see the [Contributing](https://github.com/rubberduck-vba/Rubberduck/wiki/Contributing) wiki page.
Copyright (C) 2014-2016 Mathieu Guindon & Christopher McClellan
30
+
Copyright (C) 2014-2017 Mathieu Guindon & Christopher McClellan
40
31
41
32
This program is free software: you can redistribute it and/or modify
42
33
it under the terms of the GNU General Public License as published by
@@ -53,174 +44,10 @@ along with this program. If not, see http://www.gnu.org/licenses/.
53
44
54
45
---
55
46
56
-
# Attributions
57
-
58
-
## Software & Libraries
59
-
60
-
### [Ninject](http://www.ninject.org)
61
-
62
-
**What is Ninject?**
63
-
64
-
> *Ninject is a lightning-fast, ultra-lightweight dependency injector for .NET applications. It helps you split your application into a collection of loosely-coupled, highly-cohesive pieces, and then glue them back together in a flexible manner. By using Ninject to support your software's architecture, your code will become easier to write, reuse, test, and modify.*
65
-
66
-
If you're into *Dependency Injection* and *Inversion of Control*, you'll appreciate Ninject's simple configuration API. Other than in the very specialized startup code, Ninject seems absent of Rubberduck's code base, which indeed knows nothing of Ninject or any IoC framework: don't let it fool you - Ninject is responsible for instantiating essentially.. every single class in the solution.
67
-
68
-
Rubberduck uses the following Ninject [extensions](http://www.ninject.org/extensions):
69
-
70
-
- Ninject.Extensions.Conventions
71
-
- Ninject.Extensions.Factory
72
-
- Ninject.Extensions.Interception
73
-
- Ninject.Extensions.Interception.DynamicProxy
74
-
- Ninject.Extensions.NamedScope
75
-
76
-
### [ANTLR](http://www.antlr.org/)
77
-
78
-
As of v1.2, Rubberduck is empowered by the awesomeness of ANTLR.
79
-
80
-
> **What is ANTLR?**
81
-
82
-
> *ANTLR (ANother Tool for Language Recognition) is a powerful parser generator for reading, processing, executing, or translating structured text or binary files. It's widely used to build languages, tools, and frameworks. From a grammar, ANTLR generates a parser that can build and walk parse trees.*
83
-
84
-
We're not doing half of what we could be doing with this amazing tool. Try it, see for yourself!
LibGit2Sharp is the library that has allowed us to integrate Git right into the VBA IDE (and as a nice bonus, expose a nice API that handles the nitty gritty of importing source files to and from the IDE to a repo for you).
91
-
92
-
> LibGit2Sharp brings all the might and speed of libgit2, a native Git implementation, to the managed world of .Net and Mono.
93
-
94
-
**Okay, so what is [libgit2](https://libgit2.github.com/)?**
95
-
96
-
> libgit2 is a portable, pure C implementation of the Git core methods provided as a re-entrant linkable library with a solid API, allowing you to write native speed custom Git applications in any language which supports C bindings.
97
-
98
-
Which basically means it's a reimplementation of Git in C. It also [happens to be the technology Microsoft uses for their own Git integration with Visual Studio](http://www.hanselman.com/blog/GitSupportForVisualStudioGitTFSAndVSPutIntoContext.aspx).
99
-
100
-
### [AvalonEdit](http://avalonedit.net)
101
-
102
-
Source code looks a lot better with syntax highlighting, and AvalonEdit excels at it.
103
-
104
-
> AvalonEdit is a WPF-based text editor component. It was written by [Daniel Grunwald](https://github.com/dgrunwald) for the [SharpDevelop](http://www.icsharpcode.net/OpenSource/SD/) IDE. Starting with version 5.0, AvalonEdit is released under the [MIT license](http://opensource.org/licenses/MIT).
105
-
106
-
We're currently only using a tiny bit of this code editor's functionality (more to come!).
Without the EasyHook library, many of our more advanced Unit Testing features would simply not be possible. This library really lives up to its name, and allows us to intercept and inspect traffic through VBE7.dll and other unmanged libraries.
111
-
112
-
> EasyHook makes it possible to extend (via hooking) unmanaged code APIs with pure managed functions, from within a fully managed environment on 32- or 64-bit Windows XP SP2, Windows Vista x64, Windows Server 2008 x64, Windows 7, Windows 8.1, and Windows 10.
113
-
114
-
EasyHook is released under the [MIT license](https://github.com/EasyHook/EasyHook#license).
115
-
116
-
### [WPF Localization Using RESX Files](http://www.codeproject.com/Articles/35159/WPF-Localization-Using-RESX-Files)
117
-
118
-
This library makes localizing WPF applications at runtime using resx files a breeze. Thank you [Grant Frisken](http://www.codeproject.com/script/Membership/View.aspx?mid=1079060)!
119
-
120
-
> Licensed under [The Code Project Open License](http://www.codeproject.com/info/cpol10.aspx) with the [author's permission](http://www.codeproject.com/Messages/5272045/Re-License.aspx) to re-release under the GPLv3.
121
-
122
-
## Icons
123
-
124
-
We didn't come up with these icons ourselves! Here's who did what:
125
-
126
-
### [Fugue Icons](http://p.yusukekamiyamane.com/)
127
-
128
-
This beautiful suite of professional-grade icons packs over 3,570 icons (16x16). You name it, there's an icon for that.
129
-
130
-
> (C) 2012 Yusuke Kamiyamane. All rights reserved.
131
-
These icons are licensed under a [Creative Commons Attribution 3.0 License](http://creativecommons.org/licenses/by/3.0/).
132
-
If you can't or don't want to provide attribution, please [purchase a royalty-free license](http://p.yusukekamiyamane.com/).
Icons in the `./Resources/Custom/` directory were created by (or modified using elements from) the SharpDevelop icon set licensed under the [MIT license](https://opensource.org/licenses/MIT).
Since the project's early days, JetBrains' Open-Source team has been supporting Rubberduck - and we deeply thank them for that. ReSharper has been not only a tool we couldn't do without; it's been an inspiration, the ultimate level of polished perfection to strive for in our own IDE add-in project. So just like you're missing out if you write VBA and you're not using Rubberduck, you're missing out if you write C# and aren't using ReSharper.
145
52
146
53
<sub>Note: Rubberduck is not a JetBrains product. JetBrains does not contribute and is not affiliated to the Rubberduck project in any way.</sub>
147
-
148
-
---
149
-
150
-
# Overview
151
-
152
-
The first thing you will notice of Rubberduck is its commandbar and menus; Rubberduck becomes part of the VBE, but at startup you'll notice almost everything is disabled, and the Rubberduck commandbar says "Pending":
153
-
154
-

155
-
156
-
This button is how Rubberduck keeps in sync with what's in the IDE: when it's Rubberduck itself making changes to the code, it will refresh automatically, but if you make changes to the code and then want to use Rubberduck features, you'll need Rubberduck to *parse* the code first.
157
-
158
-
The status label will display various steps:
159
-
160
-
-**Loading declarations**: Rubberduck noticed new project references and is retrieving information from the COM type libraries.
161
-
-**Parsing**: Rubberduck is creating a parse tree for each new module, and/or updating the parse trees for the modified ones.
162
-
-**Resolving declarations**: The parse trees are being traversed to identify all declarations (variables, procedures, parameters, locals, ...line labels, *everything*).
163
-
-**Resolving references**: The parse trees are being traversed again, this time to locate all identifier references and resolve them all to a specific declaration.
164
-
-**Inspecting**: At this point most features are enabled already; Rubberduck is running its inspections and displaying the results in the *inspection results* toolwindow.
165
-
166
-
That's if everything goes well. Rubberduck assumes the code it's parsing is valid, compilable code that VBA itself can understand.
167
-
168
-
It's possible you encounter (or write!) code that VBA has no problem with, but that Rubberduck's parser can't handle. When that's the case the Rubberduck commandbar will feature an "error" button:
169
-
170
-

171
-
172
-
Clicking the button brings up a tab in the *Search Results* toolwindow, from which you can double-click to navigate to the exact problematic position in the code:
173
-
174
-

175
-
176
-
The *Code Explorer* will also be displaying the corresponding module node with a red cross icon:
You'll find the *Code Explorer* under the *Navigate* menu. By default the Ctrl+R hotkey to display it instead of the VBE's own *Project Explorer*. The treeview lists not only modules, but also every single one of their members, with their signatures if you want. And you can make it arrange your modules into folders, simply by adding a `@Folder("Parent.Child")` annotation/comment to your modules:
181
-
182
-

183
-
184
-
The *inspection results* toolwindow can be displayed by pressing Ctrl+Shift+i (default hotkey), and allows you to double-click to navigate all potential issues that Rubberduck found in your code.
Rubberduck also features a port of the popular "Smart Indenter" add-in (now supports 64-bit hosts, and with a few bugfixes on top of that!), so you can turn this:
189
-
190
-
````vb
191
-
SubDoSomething()
192
-
WithActiveCell
193
-
With.Offset(1,2)
194
-
If.value>100Then
195
-
MsgBox"something"
196
-
Else
197
-
MsgBox"something else"
198
-
EndIf
199
-
EndWith
200
-
EndWith
201
-
EndSub
202
-
````
203
-
204
-
Into this:
205
-
206
-
````vb
207
-
SubDoSomething()
208
-
WithActiveCell
209
-
With.Offset(1,2)
210
-
If.value>100Then
211
-
MsgBox"something"
212
-
Else
213
-
MsgBox"something else"
214
-
EndIf
215
-
EndWith
216
-
EndWith
217
-
EndSub
218
-
````
219
-
220
-
...with a single click.
221
-
222
-
---
223
-
224
-
There's *quite a lot* to Rubberduck, the above is barely even a "quick tour"; the project's [website](http://www.rubberduckvba.com/) lists all the features, and the [wiki](https://github.com/rubberduck-vba/Rubberduck/wiki) will eventually document everything there is to document. Feel free to poke around and break things and [request features / create new issues](https://github.com/rubberduck-vba/Rubberduck/issues/new) too!
[back to readme.md](https://github.com/rubberduck-vba/Rubberduck/blob/readme-cleanup/README.md)
2
+
3
+
## What is Rubberduck?
4
+
5
+
It's an add-in for the VBA IDE, the glorious *Visual Basic Editor* (VBE) - which hasn't seen an update in this century, but that's still in use everywhere around the world. Rubberduck wants to give its users access to features you would find in the VBE if it had kept up with the features of Visual Studio and other IDE's in the past, oh, *decade* or so.
6
+
7
+
Rubberduck wants to help its users write better, cleaner, maintainable code. The many **code inspections** and **refactoring tools** help harmlessly making changes to the code, and **unit testing** helps writing a *safety net* that makes it easy to know exactly what broke when you made that *small little harmless modification*.
8
+
9
+
Rubberduck wants to bring VBA into the 21st century, and wants to see more open-source VBA repositories on [GitHub](https://github.com/) - VBA code and **source control** don't traditionally exactly work hand in hand; unless you've automated it, exporting each module one by one to your local repository, fetching the remote changes, re-importing every module one by one back into the project, ...is *a little bit* tedious. Rubberduck integrates Git into the IDE, and handles all the file handling behind the scenes - a bit like Visual Studio's *Team Explorer*.
10
+
11
+
---
12
+
13
+
If you're learning VBA, Rubberduck can help you avoid a few common beginner mistakes, and can probably show you a trick or two - even if you're only ever writing *macros*. If you're a more advanced programmer, you will appreciate the richness of [Rubberduck's feature set](https://github.com/retailcoder/Rubberduck/wiki/Features). See the [Installing](https://github.com/rubberduck-vba/Rubberduck/wiki/Installing) wiki page.
14
+
15
+
If you're a C# developer looking for a fun project to contribute to, see the [Contributing](https://github.com/rubberduck-vba/Rubberduck/wiki/Contributing) wiki page.
0 commit comments