> The number one thing I miss when trying to do java coding in TM is
> code autocompletion, and code hinting. I guess codesense is the more
> common term. I think this would probably require some kind of plugin.
I'm soooooooooooooooooooo with you on this one. This would be a killer
app for any oo language (including Actionscript, which takes up the
better part of my days) with the option for strong typing. I agree that
the plugin architecture would be needed for this.
> Second on my list would be some of the common refactoring things like
> wrap in try/catch, smart rename/delete etc.
See above.
> I'd be willing to help with some of the work.
As would I.
Allan, do you have any ideas/suggestions/resources/examples/whatever
for us to start thinking about this?
I look forward to sending screenshots of this to all of my smug,
Eclipse-using colleagues ("you develop for Flash on a MAC??!!?!?!)
:D
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.com
Allan,
Im not sure if this has been mentioned before but have you considered adding
some sort of support for project templates? Im thinking of something that
can be accessed from the File menu with no files open, that pops open a
dialog like the ³new file from template² one, a bit like the way Xcode does
it. We are in the process of making something that can be run as a command
that can sort of do this, ie: ask for user input for the project name, a
location to save the project etc and this is working quite nicely, but it
requires a document to be open to run it, which obviously isnt ideal. Do you
have any thoughts on this?
Regards
Chris Jenkins
______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________
Because it came up yesterday and I already have the bad reputation to
like Java, here it goes:
A somewhat better Java Syntax than the included one:
Features:
- Better colouring (due to the old syntax being outdated)
- Goto Symbol popup working
Bugs:
- Keep the closing parentheses and the opening brace ) { of a method
declaration on the same line, otherwise the end pattern won't match
- More to come soon ;)
Soryu
{ scopeName = 'source.java';
comment = '
Credits to Brian Lalor, who wrote the Java syntax included in TM.
I might have adapted some of his syntax.
Soryu
Comments:
• I excluded overridden anonymous Constructors from
"declaration.function.method.java", so they won''t show up in the
Goto Symbol popup to reduce clutter a little.
';
fileTypes = ( 'java' );
foldingStartMarker = '/\*\*|\{\s*$';
foldingStopMarker = '\*\*/|^\s*\}';
patterns = (
{ name = 'comment.line.double-slash.java';
begin = '//';
end = '$';
swallow = '\\\s*\n';
},
{ name = 'comment.documentation.java';
begin = '/\*\*';
end = '\*/';
patterns = (
{ match = '\*\s*(@)(param)\s*([a-z][a-zA-Z0-9_]+)\s*';
captures =
{ 1 = { name = 'keyword.other.documentation.control'; };
2 = { name = 'keyword.other.documentation.params.java'; };
3 = { name = 'keyword.other.documentation.value.java'; };
};
},
{ match = '\*\s*(@)([a-zA-Z0-9_-]+)\s*';
captures =
{ 1 = { name = 'keyword.embedded-docs.control.java'; };
2 = { name = 'keyword.embedded-docs.params.java'; };
};
},
);
},
{ name = 'comment.block.java';
begin = '/\*';
end = '\*/';
},
{ name = 'meta.package.java';
match = '(package)\s+([^ ;]+?)\s*;';
captures =
{ 1 = { name = 'keyword.other.java'; };
2 = { name = 'entity.name.package.java'; };
};
},
{ name = 'meta.import.java';
match = '(import)\s+([^ ;]+?);';
captures =
{ 1 = { name = 'keyword.other.java'; };
2 = { name = 'entity.name.class.java'; };
};
},
{ name = 'declaration.class.java';
match = '\b(?<=class|interface|enum)\s+(\w+)';
captures = { 1 = { name = 'entity.name.class.java'; }; };
},
{ name = 'other.inheritance.class.java';
comment = 'TODO: implements has multiple Parameters, Extends does
not';
match = '\b(?<=extends|implements)\s+(\w+)';
captures = { 1 = { name = 'entity.name.class.java'; }; };
},
{ name = 'declaration.function.method.java';
begin = '\b(?<!new)\s+(\w+)\s*\(';
end = '\)\s*{';
captures = { 1 = { name = 'entity.name.function.java'; }; };
patterns = ( { include = '#keywords'; } );
},
{ name = 'constant.numeric.java';
comment = 'stolen from c syntax without looking very much at it';
match = '\b((0(x|X)[0-9a-fA-F]*)|(([0-9]+\.?[0-9]*)|(\.[0-9]+))((e|
E)(\+|-)?[0-9]+)?)(L|l|UL|ul|u|U|F|f|ll|LL|ull|ULL)?\b';
},
{ name = 'keyword.flow.java';
match = '\b(if|else|while|for|return|continue|break|switch|do|goto|
case|try|catch|finally|throw)\b';
},
{ name = 'keyword.other.simple-types.java';
match = '\b(int|char|float|long|double|boolean|byte|short)\b';
},
{ name = 'keyword.operator.comparison.java';
match = '(==|!=|<=|>=|<>|<|>)';
},
{ name = 'keyword.operator.increment-decrement.java';
match = '(\-\-|\+\+)';
},
{ name = 'keyword.operator.arithmetic.java';
match = '(\-|\+|\*|\/|%)';
},
{ name = 'keyword.operator.logical.java';
match = '(!|&&|\|\|)';
},
{ name = 'storage.modifier.java';
match = '\b(private|public|protected|static|transient|final|
abstract|native|threadsafe|synchronized|volatile|strictfp)\b';
},
{ name = 'storage.type.java';
match = '\b(class|interface|enum)\b';
},
{ include = '#string-double-quoted'; },
{ include = '#keywords'; },
);
repository =
{ keywords =
{ name = 'keyword.other.java';
match = '\b(new|abstract|assert|default|synchronized|private|
protected|public|throws|enum|instanceof|transient|final|interface|
static|void|null|class|finally|strictfp|volatile|const|native|import|
package|extends|implements|this|super|true|false|if|else|while|for|
return|continue|break|switch|do|goto|case|try|catch|finally|throw|int|
char|float|long|double|boolean|byte|short)\b';
};
string-double-quoted =
{ name = 'string.quoted.double.java';
begin = '"';
end = '"';
patterns = (
{ name = 'constant.character.escaped.java';
match = '\\.';
}
);
};
};
}
Could it be that since the snap 715 the defaultkey defininition for all
application has changed. There are some definitions inside that I can't
use newline, backspace in any applications on os x.
regards
Karl-Heinz
> On 31/10/2005, at 10.59, Frédérik Bilhaut wrote:
>
> > I was wondering if TextMate has the feature often called "smart
> > home/end" in other editors ? [...]
>
> It doesn't, but you could record a macro which does:
>
> 1) move to beginning of line (ctrl A)
> 2) regexp search for: (?=\S|$)
>
> And bind that to the home key. For smart end you'd search for: (?=\s*$
Actually, this moves to the second column with lines that have no
whitespace at the front. It'd be better to do:
1) move to beginning of line (ctrl A)
2) regexp search for: (?<=\S|$)
3) move left
The regexp uses a look-behind to place the cursor after the first
non-whitespace character. Cheers,
Ben
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.com
Looking at the Ruby and Python bundles, they don't seem to have this
value set. Is indenting based on the folding markers, or what's the
deal?
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.com
Hi Folks,
TmCodeBrowser is now available as tmplugin, with a number of
enhancements:
- Keyboard navigation and search, similar to the 'Go to File...' panel
- Compatible with OS X 10.3.9 and later
- Support for Objective-C
If you currently have the old TmCodeBrowser2 installed, please de-
install it first:
- Quit TextMate
- Drag the ~/Library/InputManagersManager folder into the trash
- Drag the ~/Library/InputManagers/InputManagersManager folder into
the trash
Note: You will not be able to empty the trash until you logout or
restart!
Then install the new TmCodeBrowser.tmplugin available here:
http://www.cocoabits.com/TmCodeBrowser/
Note: Once unpacked, TmCodeBrowser.tmplugin will look like a Folder
(Allan has not added tmplugin to the CFBundleDocumentTypes in the
Info.plist file). Simply drag the TmCodeBrowser.tmplugin onto
TextMate, and TextMate will install the plugin. CodeBrowser will then
be available in the menu under 'Windows/Show CodeBrowser' (you may
need to restart TextMate for that entry to appear).
Gerd
hello.
How do I keep a command output from sending in an extra newline?
I've got a command like this:
echo $\{1:`expr $TM_SELECTED_TEXT + 1`\}
Input: Selected Text
Output: insert as snippet
Activation: ctrl-up
Scope constant.numeric
But it's no good unless I can figure out how to keep that pesky
newline from jumping in my face.
Thanks
one feature i miss from other text editors are white space indicators
and indentation guides. please see attached screenshot. note the subtle
dots which indicate spaces and the vertical dotted lines which are
usually called indentation guides. i'd love if textmate had options to
display these things.
-moshe
Add this to your language grammar of choice (from a previous thread,
sorry but I couldn't find the link in the archives):
patterns = (
/* your other patterns */
{ name = 'meta.leading-tabs.yaml';
begin = '^(?=\t)';
end = '(?=[^\t])';
patterns = (
{ match = '(\t)(\t)?';
captures =
{ 1 = { name = 'meta.odd-tab'; };
2 = { name = 'meta.even-tab'; };
};
}
);
}
)
___________________
Ben Jackson
Diretor de Desenvolvimento
+55 (21) 9997-0593
ben(a)incomumdesign.com
http://www.incomumdesign.com
On 07/11/2005, at 16.22, Matt Mower wrote:
>> This is rather difficult for me to administrate, so chances are low.
> Do you mean administering this in the menu? Or in general?
Administrate in the code/in general.
> If it was an issue about the menu being dynamic I'd be quite happy
> with Paul Bissex's suggestion of putting the last command executed in
> the status area somewhere.
Yes, it's a very good idea (and I definitely like it), but it's not
something TM was designed to do, so it's a lot of work to “add”, as
it would require several things to be done differently -- so this is
distant future…
Hi Allan,
Sometimes I find myself in the situation where I try a key combination
which doesn't do what I thought but moves the carat leaving me
uncertain what action I have just performed. I know I can hit undo
but given the non-atomic undo nature it leaves me with doubts about
whether my file is changed.
Would it be possible to add a feature that tells you what function a
key combination will invoke?
What I have in mind would be:
select "identity key"
press key combination, e.g. Cmd+Opt+V
TxMt pops up a dialog identifying the bundle & command this will activate
Choose "yes"
Executes command
Choose "no"
Does nothing
This would help me, (a) because I could work out what I *did* do, and
(b) because I could help myself learn key combos safely (by either
passing through to the action or not).
Just a thought, not sure how good of a one though ;-)
M
--
Matt Mower :: http://matt.blogs.it/
It's not exhaustive but it's a start. Kudos to the authors of the Ruby,
Python, and XML bundles for their inspiration.
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.comhttp://www.unfitforprint.com/
> I haven't figured out what the motivation is for full-screen mode
> when one can maximize the windows, and TM is already very low on
> window decorations, so the extra pixels gained from a real full-
> screen would be minimal.
I think I can speak for more than a few of the people who have
requested this when I say:
It's not about the extra pixels.
It's about minimizing distractions. There's a significant mode switch
that's triggered when all of a sudden the only thing you should be
doing is the only thing you can see on the screen. No bouncing dock
icons, no flashing news reader, no growl notifications, just your words
staring you in the face. It kind of reminds me of the good old days of
green screens and ascii text.
I've used Ulysses and honestly the only thing that made me even
consider dropping the cash on it was this one feature. It's only
implemented by one other OS X program AFAIK (MacJournal) and totally
souped up my writing productivity.
Allan, I know that we're beating a dead horse here, but no one in my
recollection seems to have brought this perspective to the table. What
are your thoughts?
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.com
I've noticed that right now displaymath modes in latex initiated by $
$ are not handled correctly. It seems that lots of times, though not
entirely consistently, they are being captured by the
string.other.math.tex scope, instead of the
string.other.math.block.latex scope.
In other words, the two dollars signs next to each other are matched
as the begining and end of a simple math mode, instead of being
considered as the beginning of a block math mode. What makes it even
weirder is that the following:
$$\int_{C_{t}}e^{g(z,t)}f(z,t)\d z$$ where $g,f$
would consider the first pair of dollar signs as
string.other.math.tex scope, and the second as the beginning of
string.other.math.block.latex, which then goes on to capture the
entire rest of the document.
So I am wondering, how is this possible that the $$ is not
consistently matched, and what can we do about it?
Haris
Try this:
1. Open a file F1 with extension .pm, Perl mode is correctly
active.
2. Open a second file F2 with extension .pm, Perl mode is
correctly active.
3. Change F2's mode to C mode.
4. Switch back to F1's tab and you'll see it's now in C mode!
Is that a bug?
-- fxn
Just in case you are wondering where does this convoluted experiment
comes from: I am working in a Perl module that has some part written
in C:
http://search.cpan.org/~fxn/Algorithm-Combinatorics/
There's a file ending in .pm that is strictly a Perl module, but that
actually is mostly C except for a few lines, since it uses Inline::C.
I need C mode there to work normally.
While we're talking about the bundle... my number one activity in
writing LaTeX is going in and out of math mode as in
\( blah \) and \[ foo \].
What is the officially encouraged LaTeX bundle way of shortening that task?
- Eric
--
Eric Hsu, Assistant Professor of Mathematics
San Francisco State University
erichsu(a)math.sfsu.edu
http://math.sfsu.edu/hsu
> One problem with full-screen apps on the Mac is the fact that good
> Cocoa interfaces don't lend themselves to a full-screen environment.
> Ulysses is a good example. It works full-screen because its interface
> is a single monolithic window, but that makes it look like hell when
> it has to share a desktop with other apps. A full screen TextMate
> would require either a significant interface change or a loss of
> functionality, and I don't know that I'd really want either of those.
I'd be happy with just being able to make the active tab take up the
full screen. I don't need access to tabs, the file drawer, or any of
the other interface elements. I just want my green text on my black
screen and nothing else. If I want to do something that will take me
out of my current mode, like switching files or tabs, I can use a
hotkey or just hit escape to get back to normal mode.
___________________
Ben Jackson
Diretor de Desenvolvimento
ben(a)incomumdesign.com
http://www.incomumdesign.com
YES!
I LOVE the textindent, thank you so much!!
Upps, after some testing, I discovered somethnig I'd still like to be
changed :)
When an empty line, let the caret remain in position, or move it "in"
just as a tab would have done. Reason; I immediately set up enter to
be a macro with newline and indent, so all code would immediately get
indented, and then I used ctrl+enter for just newline, in case I'd
ever want that. Problem was this behaviour broke rather badly since
each line without previous text had the caret far to the left. Before
setting up the macros, I'd only tested it on lines already containing
text you see..
Andreas
Version 1.03 of TmCodeBrowser is available now at
http://www.cocoabits.com/TmCodeBrowser/
NOTE: I have changed the handling of .ctags.tmcodebrowser: If
~/.ctags.tmcodebrowser does not exist, fall back to internal default.
That way users without a customized ~/.ctags.tmcodebrowser will
benefit from updates to the internal default file.
So unless you have personal customizations not covered by the default
file, please delete your ~/.ctags.tmcodebrowser, for example by
entering this line in a terminal window:
rm ~/.ctags.tmcodebrowser
Gerd
Change Log
Version 1.03:
- Possible freeze while moving the selection, fixed
- Added some quotes in Objc-C postprocessing script to avoid problems
with spaces in paths
- Added line for HTML <div> sections to the default .ctags.tmcodebrowser
- Changed handling of .ctags.tmcodebrowser: If ~/.ctags.tmcodebrowser
does not exist, fall back to internal default. That way users without
a customized ~/.ctags.tmcodebrowser will benefit from updates to the
internal default file
- Changed CFBundleVersion to a growing integer in preparation for
automatic version checks by TextMate
- Fixed tabbing through the CodeBrowser panel
I am one of the few (?) people who experience a crash in the find
dialog, when using <tab>.
Now, something similiar happened when using the tab key inside the
search field of TmCodeBrowser, the Beachball spun out on me.
I sampled Textmate and attached the file,
maybe Gerd or Allan can see something strange in there.
Soryu
Since I've found on informations about student discounts, I assume there
are none. Am I correct?
I just would like to avoid learning they existed *after* buying
TextMate...
Thanx in advance,
-riko