Welcome Guest.   Make a donation to an author on the site October 22, 2014, 04:40:08 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
The N.A.N.Y. Challenge 2011! Download 30+ custom programs!
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: Prev 1 2 3 [4] 5 Next   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: NANY 2010 Release: ClipTrap  (Read 43892 times)
BGM
Participant
*
Posts: 82


see users location on a map View Profile Give some DonationCredits to this forum member
« Reply #75 on: July 14, 2012, 03:01:44 PM »

Skwire,  It happened again, and this time, I did some testing and narrowed it down to the point where I can successively reproduce the failure.

The GUI is fine as long as it is running, but if there are too many characters in clip.txt when ClipTrap starts up, the GUI fails to load completely - the application starts, and it still captures, but GUI doesn't function right.  (I have some screenshots I can email to you if you like).

So, to reproduce the GUI failure, close ClipTrap, create an empty clip.txt file, and paste "some string in this here line" (without the quotes) till you have 14922 lines of that phrase.  ClipTrap will start okay with this.  Now close ClipTrap and add one more line to the clip.txt.  When you restart ClipTrap, the error should happen. 

Now, I don't think it has to do with the number of lines - that is, the number of carriage return/line feeds.  Because, if you take those 14922 lines + 1 and join them so that you only have one line, ClipTrap will start okay - but if you duplicate that really long line so that you have two lines, ClipTrap *won't* start.

So, it is just the GUI that has issues when it starts.  If it is already started, you can have millions of lines in your clip.text and it is okay.

Anyway, there are a few ideas to play around with.
Logged

-BGM
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #76 on: July 14, 2012, 06:30:55 PM »

Skwire,  It happened again, and this time, I did some testing and narrowed it down to the point where I can successively reproduce the failure.

Awesome.  Thanks for taking the time to figure this out.  I think I've worked around the issue in this build.  Please try it out and let me know.  Thanks.

Website | Download
v1.1.2 - 2012-07-14
    ! Worked around an issue when attempting to load a large amount of
      saved text when ClipTrap starts.  (Thanks, BGM)
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #77 on: August 14, 2012, 05:50:33 PM »

Enhancement Request:

Add button in top region, "Send All To Text File, Clear Window Text, Then Exit."

Window pops up asking for name of file.

Presto, all done.

Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #78 on: August 14, 2012, 06:29:58 PM »

I can add a Save button but that's all it will do, offer to save the contents as a file.  Clear Window Text and Exit are already handled.  In other words, I like to keep things abstract.  Cool?
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #79 on: August 14, 2012, 06:36:03 PM »

The key is to make it as easy as possible to get ClipTrap contents into a file, and to exit.

In and out.  Job accomplished.

Preferably in the .ini file you can keep track of the preferred path in which to save the file.  Maybe even a default file name.

Very cool.

Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #80 on: August 14, 2012, 07:34:15 PM »

The key is to make it as easy as possible to get ClipTrap contents into a file, and to exit.

Oh, I understand the reason but keep in mind that I like to keep things somewhat standard when it comes to user interfaces.  One button that does three actions like that isn't very standard.

Preferably in the .ini file you can keep track of the preferred path in which to save the file.  Maybe even a default file name.

I'll make it remember the last used path.
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #81 on: August 14, 2012, 07:41:44 PM »

Just a thought, then:

"Execute Default Script" button.

Perhaps user has the opportunity to put a number of sequential steps into the .ini file.

That way it can be a custom-made thing, because different users probably would want to be able to rapidly do different things.

Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #82 on: August 14, 2012, 09:46:55 PM »

Here you go, Nick.

Website | Download
v1.1.3 - 2012-08-14
    + Added "Save text as..." functionality via the toolbar, File menu, or Ctrl+S hotkey.  (Thanks, nkormanik)
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #83 on: August 15, 2012, 01:12:19 AM »


Really nice addition to a terrific program, Skwire.  Thank you!

Makes getting copied content safely saved away into a text file so much faster.

Glad you decided to have ClipTrap remember the last directory where things are saved, and use that as default presently.  No need to fiddle around searching for the right place.

Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #84 on: August 15, 2012, 06:16:52 PM »


Just my own personal opinion, but...

I think the "Save text" feature is so important that it warrants a larger button, same size as the "Scroll to top" and "Scroll to bottom" buttons.  With text.  And I think it should be placed to the right of "Append clips to..."

You know me -- always wanting more.


Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #85 on: August 22, 2012, 07:13:28 PM »


In addition to the previous suggestion, here's another:

To the right of the nice large "Save text" button..., add "Append text"

When user clicks on "Append text" button, a little window comes up remembering last saved location AND the last used file name.  Last used File name is populating the proper space where file name usually goes.

Click okay, and presto, window contents are appended to that file.

Clear the ClipTrap window, exit, all done.


Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #86 on: August 22, 2012, 09:02:53 PM »


At the very least, have ClipTrap remember the previously used file name.

Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #87 on: August 23, 2012, 04:05:22 PM »


By the way, I've noticed that when ClipTrap saves text to a file..., there is some added semi-invisible code at the very beginning of the created file.  Said code prevents a regular text editor from editing the text file.

In a more powerful text editor this is how the code appears:



Somehow it would be best to prevent that code from making it into the newly created text file.

Thanks!


Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #88 on: August 23, 2012, 04:58:19 PM »

In a more powerful text editor this is how the code appears:



Somehow it would be best to prevent that code from making it into the newly created text file.

That is the UTF-8 Byte Order Mark.  ClipTrap supports Unicode and writes to UTF-8 format.  Lesser editors that do not support UTF-8 may have trouble with opening these files (as you have seen).  I don't believe I can change this behaviour in AHK but I'll check.  If Unicode support is not important to you, use the ANSI version of ClipTrap (ClipTrap_ANSI.exe) instead.  It does not write in UTF-8 format (and doesn't support Unicode).
« Last Edit: August 23, 2012, 08:40:06 PM by skwire » Logged

Cattleya
Participant
*
Posts: 1

View Profile Give some DonationCredits to this forum member
« Reply #89 on: October 22, 2012, 04:32:01 AM »

Can you share me the software source code, many thanks! smiley
Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #90 on: October 22, 2012, 08:27:31 AM »

Hi, Cattleya, and welcome to the DonationCoder site.  My software is freeware but it's not open source.  Was there a particular feature you'd like to see added to ClipTrap?
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #91 on: October 24, 2012, 06:50:56 PM »


Enhancement Request:

Skwire, please allow for the inclusion of default name in the "Save text as" box.

Have the name automatically populate the box.

Best if user can pre-select it, and that pre-selection saved in the .ini configurations file.

But, if not, then something like "ClipTrapped.txt."

Thanks!

Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #92 on: October 24, 2012, 09:35:07 PM »

Website | Download
v1.1.4 - 2012-10-24
    + Last used filename is now saved.  (Thanks, nkormanik)
    * No longer writes the Unicode BOM to files.
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #93 on: October 24, 2012, 11:25:05 PM »

Thanks, as always, Skwire.
Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #94 on: October 25, 2012, 12:38:04 AM »


Further request:

Upon save, if file exists, offer to append or replace, with default being to append.

As of right now ClipTrap overwrites an existing file without any notice.  Poof.  All the previous clippings saved vanish and are substituted with a new set.  User ought to at least get a warning.

By the way, with append (to existing file), I can see the usefulness of including your "Enable timestamp tokens," which I've not thought about using before.

Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #95 on: October 25, 2012, 10:43:20 AM »

As of right now ClipTrap overwrites an existing file without any notice.  Poof.  All the previous clippings saved vanish and are substituted with a new set.  User ought to at least get a warning.

I'm not sure what you're getting at.  If you try to save using a filename that already exists, you will get the standard "blah blah already exists.  Do you want to replace it?"  Is that not notice enough?
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #96 on: October 25, 2012, 03:19:06 PM »

Very strange you get a warning.  I tried twice and didn't get one.

As said, ClipTrap simply silently overwrote the original, and replaced.  Poof.

How about the "Append to file" possibility?
Logged
nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #97 on: October 26, 2012, 01:32:09 AM »

Same result on a different computer.  No warning at all.  Simply overwrote.
Logged
skwire
Global Moderator
*****
Posts: 4,113



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #98 on: October 26, 2012, 09:34:11 AM »

Very strange you get a warning.  I tried twice and didn't get one.
As said, ClipTrap simply silently overwrote the original, and replaced.  Poof.

I tested on both XP and W7 and it works for me.  Here's a quick screencast I made: http://skwire.dcmembers.c...iptrap/sc/ClipTrap_01.swf

How about the "Append to file" possibility?

Website | Download
v1.1.5 - 2012-10-26
    + Added "Append text to..." functionality via the toolbar, File menu,
      or Ctrl+D hotkey.  (Thanks, nkormanik)
Logged

nkormanik
Participant
*
Posts: 285

View Profile Give some DonationCredits to this forum member
« Reply #99 on: October 28, 2012, 03:40:38 AM »


Append works great, Skwire.  Huge and really useful addition to your Cliptrap program.  Thanks very much!

I realized the problem with overwrite....  Must include the extension with the name of the file.  Sometimes (not sure exactly when or why) all that's necessary to save a file is just the filename, and, say, .txt, is automatically added.  Well, if only filename is given, Cliptrap will overwrite the saved file that includes the extension.

So, when saving a file from Cliptrap, very important to type in the filename + the extension.  Then if such file already exists, Cliptrap will give a warning about overwriting.

Logged
Pages: Prev 1 2 3 [4] 5 Next   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.042s | Server load: 0.02 ]