[gedit-list] Can't open a 2.6MB file (Paolo Borelli)



On Sun, 2005-08-28 at 12:00 -0400, gedit-list-request gnome org wrote:
> Send gedit-list mailing list submissions to
> 	gedit-list gnome org
> 
> To subscribe or unsubscribe via the World Wide Web, visit
> 	http://mail.gnome.org/mailman/listinfo/gedit-list
> or, via email, send a message with subject or body 'help' to
> 	gedit-list-request gnome org
> 
> You can reach the person managing the list at
> 	gedit-list-owner gnome org
> 
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of gedit-list digest..."
> 
> 
> Today's Topics:
> 
>    1.  Re: gedit-list Digest, Vol 7, Issue 7 (Kenneth B. Hill)
>    2. Re:  Re: gedit-list Digest, Vol 7, Issue 7 (Paolo Borelli)
> 
> 
> ----------------------------------------------------------------------
> 
> Message: 1
> Date: Sat, 27 Aug 2005 17:25:37 -0700
> From: "Kenneth B. Hill" <ken scottshill com>
> Subject: [gedit-list] Re: gedit-list Digest, Vol 7, Issue 7
> To: gedit-list gnome org
> Message-ID: <1125188737 26545 2 camel localhost>
> Content-Type: text/plain
> 
> On Fri, 2005-08-26 at 12:00 -0400, gedit-list-request gnome org wrote:
> > Send gedit-list mailing list submissions to
> > 	gedit-list gnome org
> > 
> > To subscribe or unsubscribe via the World Wide Web, visit
> > 	http://mail.gnome.org/mailman/listinfo/gedit-list
> > or, via email, send a message with subject or body 'help' to
> > 	gedit-list-request gnome org
> > 
> > You can reach the person managing the list at
> > 	gedit-list-owner gnome org
> > 
> > When replying, please edit your Subject line so it is more specific
> > than "Re: Contents of gedit-list digest..."
> > 
> > 
> > Today's Topics:
> > 
> >    1. Re:  Can't open a 2.6MB file (Marc D. Murray)
> >    2. Re:  Can't open a 2.6MB file (Paolo Borelli)
> > 
> > 
> > ----------------------------------------------------------------------
> > 
> > Message: 1
> > Date: Thu, 25 Aug 2005 11:21:04 -0500
> > From: "Marc D. Murray" <marcdm phronein com>
> > Subject: Re: [gedit-list] Can't open a 2.6MB file
> > To: gedit-list gnome org
> > Message-ID: <430DEFF0 1010008 phronein com>
> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed
> > 
> > I'm using the Gedit packaged with Ununtu 5.04 (gedit 2.10.2) and I've 
> > managed to open text files as big as 138MB in gedit.
> > 
> > If line-wrapping is enabled it takes forever to open if there are long 
> > lines. But, killall gedit, disable line-wrapping, re-open file and I'm 
> > good to go.
> > 
> > HTH.
> > 
> > Marc DM
> > 
> > Paolo Borelli wrote:
> > 
> > >Il giorno mer, 24/08/2005 alle 17.39 -0700, Kenneth B. Hill ha scritto:
> > >  
> > >
> > >>Is there a file size limit for a file that gedit can open? I'm trying to
> > >>open a 2.6MB size file, and it just "hangs" and I have to force quit it.
> > >>If there is a sixe limit for gedit, then can you recommend another gnome
> > >>text editor that can handle larger files? Thank you.
> > >>
> > >>    
> > >>
> > >
> > >There shouldn't be any size limit, though opening very big files may be
> > >a little slow and hang the interface for a while in the current
> > >version , since the loading is done synchronously. However 2.6 MB
> > >doesn't seem that big... I just tried a 1.3MB (the biggest I could find
> > >in my /var/log) and it opened pretty fast without any problems.
> > >
> > >
> > >ciao
> > >	Paolo
> > >
> > >_______________________________________________
> > >gedit-list mailing list
> > >gedit-list gnome org
> > >http://mail.gnome.org/mailman/listinfo/gedit-list
> > >
> > >
> > >  
> > >
> > 
> > 
> > 
> > ------------------------------
> > 
> > Message: 2
> > Date: Thu, 25 Aug 2005 19:21:42 +0200
> > From: Paolo Borelli <pborelli katamail com>
> > Subject: Re: [gedit-list] Can't open a 2.6MB file
> > To: "Kenneth B.Hill" <ken scottshill com>
> > Cc: gedit-list gnome org
> > Message-ID: <1124990502 25877 12 camel localhost localdomain>
> > Content-Type: text/plain
> > 
> > Il giorno gio, 25/08/2005 alle 10.18 -0700, Kenneth B.Hill ha scritto:
> > > On Aug 25, 2005, at 2:54 AM, Paolo Borelli wrote:
> > > 
> > > > Il giorno mer, 24/08/2005 alle 17.39 -0700, Kenneth B. Hill ha scritto:
> > > >> Is there a file size limit for a file that gedit can open? I'm trying 
> > > >> to
> > > >> open a 2.6MB size file, and it just "hangs" and I have to force quit 
> > > >> it.
> > > >> If there is a sixe limit for gedit, then can you recommend another 
> > > >> gnome
> > > >> text editor that can handle larger files? Thank you.
> > > >>
> > > >
> > > > There shouldn't be any size limit, though opening very big files may be
> > > > a little slow and hang the interface for a while in the current
> > > > version , since the loading is done synchronously. However 2.6 MB
> > > > doesn't seem that big... I just tried a 1.3MB (the biggest I could find
> > > > in my /var/log) and it opened pretty fast without any problems.
> > > >
> > > >
> > > > ciao
> > > > 	Paolo
> > > >
> > > >
> > > I just checked my PC; it has 233MB of RAM. I am able to open the 2.6MB 
> > > file, but when I try and do a search-and-replace (| => ',') the gedit 
> > > app hangs. I'm thinking more memory in the PC will help.
> > 
> > [I inadvertitely removed gedit-list from cc in the previous response]
> > 
> > As suggested by another guy, does the file in question have very long
> > lines and you have word wrapping turned on? This can cause big
> > performance problems... unfortunately it's a pathological behavior of
> > GtkTextView and we can't do much about it.
> > 
> > Paolo
> > 
> > 
> > 
> > ------------------------------
> > 
> > _______________________________________________
> > gedit-list mailing list
> > gedit-list gnome org
> > http://mail.gnome.org/mailman/listinfo/gedit-list
> > 
> > 
> > End of gedit-list Digest, Vol 7, Issue 7
> > ****************************************
> 
> I do have word-wrap turned on. I turned it off and it still gives me the
> same proble of hanging. The lines in the file are not long 30 chars
> length for each line. The problem seems to come when I do a Replace
> function to search for the | character and replace it with the ','
> characters. There are several thousands instances of the | character in
> the file.
> 
> Is there perhaps a command line that I can use?
> 
> 
> 
> ------------------------------
> 
> Message: 2
> Date: Sun, 28 Aug 2005 12:26:14 +0200
> From: Paolo Borelli <pborelli katamail com>
> Subject: Re: [gedit-list] Re: gedit-list Digest, Vol 7, Issue 7
> To: ken scottshill com
> Cc: gedit-list gnome org
> Message-ID: <1125224774 6543 5 camel localhost localdomain>
> Content-Type: text/plain
> 
> 
> > I do have word-wrap turned on. I turned it off and it still gives me the
> > same proble of hanging. The lines in the file are not long 30 chars
> > length for each line. The problem seems to come when I do a Replace
> > function to search for the | character and replace it with the ','
> > characters. There are several thousands instances of the | character in
> > the file.
> > 
> 
> This explains some things, search&replace speed needs to be improved,
> but it's easier said than done :)
> You may try to make the search case sensitive which should improve
> things quite a bit.
> 
> > Is there perhaps a command line that I can use?
> > 
> 
> Sure, you can use 'sed' (which outputs the processed file) or use this
> simple perl command which edits the file in place: perl -p -i -e
> 's/\|/,/g' yourfile.txt
> 
> ciao
> 
> Paolo
> 
> 
> 
> ------------------------------
> 
> _______________________________________________
> gedit-list mailing list
> gedit-list gnome org
> http://mail.gnome.org/mailman/listinfo/gedit-list
> 
> 
> End of gedit-list Digest, Vol 7, Issue 8
> ****************************************

Paolo, that perl command works much faster. I'm not too familar about
using perl. Can you point me to a reference that provides a good
introduction to using perl? Thanks again!

-Ken




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]