Skip to main content

Posts

Showing posts from 2015

Quick way to show documentation in NetBeans

Holding the control key [command key in Mac OS X] in NetBeans will mark functions, methods, and variables with an underline.  Holding the key and hovering over functions and methods will reveal their documentation in a sort of tool tip, if such documentation is available.  This is in addition to opening the documentation panel with the Control + Shift + Space key combination. Function documentation on usage with Control + Hover. The presentation of the documentation tip is available with the Control + Hover event on method definitions as well as their usage.  Oddly however, it's not available with function definitions.  With function definitions, the IDE presents a brief, and unhelpful tool tip just identifying the function and the file it belongs to. Function documentation on definition with Control + Hover.  Note that nothing meaningful is rendered as it is with the usage example. It should be noted, that the details identified here are using NetBeans 8.1

Undo moving items to the trash

The main desktop operating systems today have provisions for putting files back to where they came from if it's determined that they were put in the trash by mistake. Mac OS X Option 1 From the Finder, Edit | Undo Move of "Filename" (Command + Z) Option 2 Open the Trash and locate the file to restore, then Right-click | Put Back . Ubuntu Using Ubuntu , there are three methods for restoring files that have been moved to the trash. Option 1 Assuming that a file browser window is open (Nautilus) and no other editing actions have taken place, choose Edit | Undo Trash . Option 2 Open the Trash window and choose Right-click | Restore on the file to put back to where it came from. Option 3 Open the Trash window, select the file to restore, and click the Restore button in the upper right corner of the window. Windows With Windows , there are two techniques. Option 1 From any Explorer window choose Edit | Undo .  Assuming the previous operati

Set the iOS calendar Widget presentation in Notification Center

The calendar Widget in the Notification Center of Apple 's iOS will match the view in the iOS calendar application.  If the calendar view is set to the "agenda view," it will be the agenda view in the Notification center as well.  Likewise, the "day view" will be reflected in the widget too. The agenda view is selected in the iOS Calendar application. The day view is selected in the iOS Calendar application. It should be noted that the view selection in Apple's calendar application can only be made for the current day.

Oracle SQL Developer supports SQL Server via jTDS driver

Pardon the confusion with all the freely flung usage of the term SQL coupled with the vaguely descriptive "developer" and "server" terms.  This article describes the requirements for getting Oracle 's SQL Developer client to work with Microsoft 's SQL Server database manager. SQL Developer supports connections to SQL Server, but in spite of Microsoft providing its own JDBC driver , SQL Developer will only work with the jTDS driver.  Download that and point SQL Developer to it via: Tools | Preferences… Database | Third Party JDBC Drivers Point SQL Developer to the jTDS driver to use with SQL Server. If connections are being made from the Windows version and Windows authentication will be necessary, then the ntlmauth.dll library will need to be copied into the JDK directory: Copy from PATH_TO_JTDS\jtds-VERSION\PLATFORM\SSO\ntlmauth.dll Copy to JAVA_JDK_DIRETORY\jre\bin\ntlmauth.dll

Reveal files in gedit file browser view (Windows)

Use the filter option to show binary files to make the files available. Right + click in the File Browser tab's file listing area Select Filter | Show Binary Gedit , the open source text editor for Gnome , has a view in the side panel to browse the local file system.  It appears that the Windows version of the application has a bug that assumes all files to be binary, even if they carry a .txt filename suffix. The expected behavior is that text and source code files will be listed by default, and that this option will allow items like pictures and executable files to be shown as well.  Setting this flag can serve as a workaround.  Without it, only folders and files without filename suffixes will be shown. Gnome Bugzilla ( 578829 ) File Browser plugin can only show files with no extension on Win32 https://bugzilla.gnome.org/show_bug.cgi?id=578829

Several options for providing query parameters to 'queryExecute' function

The params argument of the queryExecute() function can be passed in a number of forms.  Using an object or a structure will allow named query parameters, while the array method necessitates the question mark (?) placeholders. Because of this difference, the SQL variable has been defined twice, once in each manner.  The query is run and the result is dumped in the final example. Object and structure methods // Params definition option 1. var sqlParams =     {         firstParam: "FIELD VALUE",         secondParam: "FIELD VALUE"     } // Params definition option 2. var sqlParams = structNew (); sqlParams . firstParam = "FIELD VALUE" ; sqlParams . secondParam = "FIELD VALUE" ; // Params definition option 3. var sqlParams = structNew (); sqlParams [ "firstParam" ] = "FIELD VALUE" ; sqlParams [ "secondParam" ] = "FIELD VALUE" ; var sql = "     declare @returnValue nvarchar(255)     exec

Resolve 'Detecting library folders' error in Eclipse

Eclipse maintains a directory at the root of a project with the name ".settings."  If, for whatever reason, Eclipse can't seem to find this directory, or the files in it, Eclipse will report an error vaguely stating a problem "Detecting library folders."  Removing the .settings directory will solve the problem. Presumably, Eclipse rebuilds any information it maintains in that directory, though it's not clear what the information is.  Assume that any arbitrary details that seem off might be associated with removing this folder. The "Detecting library folders" error dialogue window. Due to the non sequitur nature of the error, there isn't much context to work off of other than the "org.eclipse.wst.validation" identifier, and the "detecting library folders" pseudo-clue.  As such, there isn't much that comes back from searches around the web for solutions to the issue, but the combination of the three references

Quickly reveal definitions in Eclipse PDT

Eclipse PDT (PHP Development Tools) has the ability to quickly show the definitions of functions and methods by hovering the cursor over the parentheses of a reference.  This feature is an extension of the typical docblock or signature reveal when hovering over a method or function call itself. It's not as easy to hover over a parenthesis as it is to hover over a function reference, so invoking the tip can be a little clumsy.  And there's another peculiarity with the feature too.  Typically, the inline popups like this are "focusable" by moving the mouse from a hover into the pop-up.  For these pop-ups though, they immediately disappear when moving away from the parentheses.  Instead, use the F2 key to focus the pop-up.  In spite of these usability matters, the feature is handy as a quick reference and is welcome. It's possible that other Eclipse plug-ins have a similar feature to, so in order to get an idea as to whether or not this is a feature of th

Public versus private properties in CFML

It's not immediately clear how to differentiate between public and private properties in CFML CFC s (ColdFusion Components, which in turn are classes).  Defining methods is more straightforward, in that they provide for public and private keywords to signal their scope.  It would stand to reason that these scoping keywords might also be applicable for properties as well.  After all, this is the approach taken with other languages such as Java and PHP . Alas, it is not the case.  And to compound matters, searching the Web doesn't really provide much clarification on the matter either.  Answers range from, it's just not possible, to initializing variables in the constructor to make them act like private properties. The examples provided here bear out that, CFML, at least running on Railo / Lucee , do in fact, support the scoping of properties.  It works like this.  Properties intitialized using the this.variableName form are public.  Simply initializing a variable with

Migrating Eclipse projects to new locations

Preface To begin with, the operation described here is something that falls outside of the way Eclipse is meant to be worked with.  Eclipse has a concept of "Workspaces" to allow the IDE to be completely reconfigured for the type of development that is being done. This is a great idea in theory, but in practice it can be quite cumbersome and off-putting.  Off-putting simply because changing a Workspace means that everything needs to be reconfigured again.  Font colors, view locations, and who knows what else. It's true that creating a new Workspace allows the Workbench Layout and Working Sets to be copied.  And the settings can be exported from one Workspace to the next.  Still, once all of this is done, if changes are made in one, they would have to be applied to any of the other Workspaces that have been create as well, if one wants to maintain a consistent environment across all projects.  Plus, it doesn't really work anyway.  All Views still need to be repl

Tell Git to use a specific 'ignore' file

Use the git config command to point Git to a custom location for storing the listing of files to ignore in repositories. git config --global core.excludesfile ~/.gitignore Additionally, the setting can be added by editing the config file directly.  The config file is at the root of the user's home directory and is named ".gitconfig." Most articles around the Web instructing users how to ignore specific types of files across repositories, describe creating a file named ".gitignore."  Almost without fail, the instructions suggest putting the .gitignore file at the root of the user's home direcory. ~/.gitignore The expectation is that this is a location that Git looks at by default to pick up any files that it should ignore.  It does not.  Rather, the default locations that Git looks to are: $XDG_CONFIG_HOME/git/ignore $HOME/.config/git/ignore If the first place is not found, then the second place is checked.  Git will not look at ~/.giti

Eclipse KB: New projects are not allowed

Issue Attempts to create or import a project consistently fail stating that a project with the specific name already exists.  However, the project does not appear in the explorer or navigator views. Cause The issue is because Eclipse is set to list only a certain set of projects (Working Set). Solution The steps to resolve this issue will depend on the "file" view in use.  This means things like an explorer ( PHP Explorer for instance) or the Navigator.  There is a downward pointing triangle, most likely along the top right of the view. View Menu | Select Working Set… Choose a combination of options The selection in the second step should probably be Window Working Set or No Working Set . Environment Version Eclipse 4.4 Luna (any version that supports working sets) OS Any Browser Not applicable Details There is no clear indication or any sort of visual cue to make it readily known that the projects in a listing are for a specific

GitEye KB: Version 1.9 update fails

Issue GitEye version 1.9.x may fail with a time out error during its update procedure. The error reported may resemble the example below. An error occurred while collecting items to be installed session context was:(profile=DefaultProfile, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=). Unable to read repository at http://downloads.open.collab.net/git/giteye/release/plugins/org.eclipse.core.databinding_1.4.2.v20140729-1044.jar. Read timed out Unable to read repository at http://downloads.open.collab.net/git/giteye/release/plugins/org.eclipse.core.filesystem_1.4.100.v20140514-1614.jar. Read timed out Cause The reason why this happens isn't easily identified.  The indication of a timeout issue though leads suspicion towards things like a slow data connection or too many packages to update for the allotted time the package manager has specified. Solution Repeated attempts to update the software may eventually resolve the issue.

Enable missing disclosure triangles in Finder

The problem is with the arrangement chosen for the list view.  Using any of the following methods, choose Arrange By | None : The View menu from menubar The gear icon in the Finder window The contextual menu (right + click mouse button) The Finder in Mac OS X is the application is always running and provides access to the file system of the computer.  This is the Windows Explorer on Windows systems, or something like Nautilus on Gnome -based Linux systems.  The primary interface is a folder paradigm that presents files and folders in a number of different views. On the Mac, these views are icons, list, columns, and Cover Flow .  To the Finder, the list view is a "stacked" presentation of the files with alternating background colors and a nice feature Apple calls a " disclosure triangle ."  This control is present on directory items, and when clicked, will either expand the listing to show a nested view of the contents of that folder or contract