Welcome, Guest. Please login or register.
September 02, 2010, 01:25:39 PM
Home Help Search Login Register
News: Tinycore is here 12/1/2008! Welcome visitors. Community gatherings on Freenode at #tinycorelinux (webchat)

[Recent Topics] [Main . Forum . Wiki]
+  tinycorelinux.com
|-+  Tiny Core Extensions
| |-+  TCE Talk
| | |-+  flPicSee version 0.9.1
« previous next »
Pages: [1] 2 Go Down Print
Author Topic: flPicSee version 0.9.1  (Read 3014 times)
MikeLockmoore
Full Member
***
Offline Offline

Posts: 240


« on: May 25, 2009, 01:55:45 PM »

I'm posting a new version of flPicSee today.  It has a right-click menu with some additional zoom levels, an about box, and a very simple help box.  It also allows you to select another file with the standard file chooser. 

This version has done away with the middle-click zoom-change behavior.  Now if you click the left mouse button without dragging, the zoom changes (based on the window size and image size).  If, instead, you click and drag the the mouse with the left button, and the image size is larger than the curren window size, the image will be dragged around with the mouse, allowing you to pan the image.
You may still use a mouse scroll wheel to change the zoom settings.

This version is a bit over 14 KB, but the make file has a new build config option that omits the right-click menu stuff and makes flPicSee about 11.5 KB.  I hope in later versions to add additional features, so there will be one or more "delux" build configuration options as well.

DISCLAIMER: I've only tested with version 1.3 with JWM so far .  Perhaps tonight or sometime soon I'll try with TC 1.4.3 and 2.0 rc2.  But if you have any issues with flPicSee, please post a description of it here and your current TinyCore configuration (TC Base version and  window manager, at least).


I'll post the source code and make file in reply below.

Hope people find it useful!
--
Mike L.
Logged
MikeLockmoore
Full Member
***
Offline Offline

Posts: 240


« Reply #1 on: May 25, 2009, 02:00:05 PM »

Here is the source code and make file for flPicSee version 0.9.1.
--
Mike L.
Logged
curaga
Administrator
*****
Offline Offline

Posts: 3256



« Reply #2 on: May 25, 2009, 02:10:29 PM »

This probably won't matter with TC, but your code is not 64-bit clean: flpicsee.cpp:530: error: cast from 'void*' to 'int' loses precision

There's a very easy solution, that makes things work on 64 while still working on 32:
Quote
--- flpicsee.cpp   2009-05-25 23:08:28.000000000 +0300
+++ flpicsee.cpp.new   2009-05-25 23:06:19.000000000 +0300
@@ -527,7 +527,7 @@
 #ifdef INCL_MENU
 static void MenuCB(Fl_Widget* window_p, void *userdata)   
 {
-   int choice = (int)userdata;
+   long choice = (long)userdata;
    int spec_w, spec_h;
    float speczoomfactor;
 
Logged

The only barriers that can stop you are the ones you create yourself.
MikeLockmoore
Full Member
***
Offline Offline

Posts: 240


« Reply #3 on: May 25, 2009, 07:11:06 PM »

Thanks, curaga.

Posting from TC 1.4.3, by the way.
Logged
junan
Jr. Member
**
Offline Offline

Posts: 88


« Reply #4 on: May 25, 2009, 08:33:07 PM »

works with tce 2.x. but there is another flpicsee at /usr/bin/flpicsee.
if i call from aterm with flpicsee , it will call /usr/local/bin/flpicsee ,
your version. nice improvement , i can open another picture
without closing it first Smiley
Logged

fun and fearless ...
roberts
Administrator
*****
Offline Offline

Posts: 3718



WWW
« Reply #5 on: May 25, 2009, 09:40:30 PM »

That is because I have been featuring Mike's work in the base system.
Mike keeps improving his program!
Logged

Don't Ignore What's in Core.
roberts
Administrator
*****
Offline Offline

Posts: 3718



WWW
« Reply #6 on: June 02, 2009, 05:50:36 PM »

On TCv2.0rc4 in both flwm and jwm, if a pic is 100% scale in initial window and I right click to zoom larger, thinking that I could then able to pan the image, instead I get a seg fault program abort.
Logged

Don't Ignore What's in Core.
curaga
Administrator
*****
Offline Offline

Posts: 3256



« Reply #7 on: June 03, 2009, 05:05:08 AM »

The file check should be done before checking for the file extension, for example running "flpicsee garbage" prints the contents of random memory as the file type.
Logged

The only barriers that can stop you are the ones you create yourself.
MikeLockmoore
Full Member
***
Offline Offline

Posts: 240


« Reply #8 on: June 03, 2009, 10:17:04 PM »

roberts: Did you use the .tce I provided in TC 2.0rc4?  Or was it your own build?  If it was your own build, which options were used?  I tried to build it with and without the -DNO_MENU option and I don't see that kind of behaviour happen in TC 1.4.3 or TC 2.0rc2.  I may yet get to testing on TC 2.0rc4, but perhaps not for a few days.  As posted earlier, my main TC development machine is a laptop with a non-core ACX chipset WiFi adapter, and with a busted CD-ROM drive, and it will take a bit of fiddling to get that laptop fully usable with TC 2.0 like it is for 1.x.

curaga: I can't reproduce that behaviour with flPicSee version 0.9.1. I see a message box saying "File 'garbage' is not a known image type.  flPicSee will exit." At least when running on TC 1.4.3.  Are you running that version?  NOTE: flPicSee should be recompiled for TC 2.0, so don't try to run my .tce on TC 2.0, if that is what you are doing.
--
Mike L.
« Last Edit: June 03, 2009, 10:18:35 PM by MikeLockmoore » Logged
roberts
Administrator
*****
Offline Offline

Posts: 3718



WWW
« Reply #9 on: June 03, 2009, 10:32:24 PM »

Mike,

I had tested my build and saw the abort, then download your posted build and saw the same abort on 2.0rc4.

After seeing your latest post. I tested my build on 1.4.3 and no abort. It works as I had expected.
Logged

Don't Ignore What's in Core.
curaga
Administrator
*****
Offline Offline

Posts: 3256



« Reply #10 on: June 04, 2009, 02:45:33 AM »

Heh, I had an older version Tongue
Logged

The only barriers that can stop you are the ones you create yourself.
meo
Full Member
***
Offline Offline

Posts: 228


« Reply #11 on: June 04, 2009, 02:53:42 AM »

Hi MikeLockmoore!

I downloaded your version and is using this extension with Microcore and everything seems to work just fine. Thanks for a good work.

Have fun,
meo
Logged

"All that is very well," answered Candide, "but let us cultivate our garden." - Francois-Marie Arouet Voltaire
JoXo009
Full Member
***
Offline Offline

Posts: 152


« Reply #12 on: October 22, 2009, 04:05:14 AM »

Hi MikeLockmoore!
your flpicsee is a nice program.

Think about using it as tool to present background help information within my virtual TC install.

For this purpose it would be of advantage to set the window title ("Help info" for example instead of "100% ..."), to switch off mouse zooming and maybe even to set window opening position.

Do you see a possibility to produce a future flpicsee with the option -title "XXXXXX"?
Logged
MikeLockmoore
Full Member
***
Offline Offline

Posts: 240


« Reply #13 on: October 22, 2009, 06:45:38 AM »

JoXo009: Hmmm, perhaps that could be added, but I may not get to that very quickly.  If you are handy in C, you could try, of course. - ML
Logged
curaga
Administrator
*****
Offline Offline

Posts: 3256



« Reply #14 on: October 30, 2009, 04:40:01 AM »

Does flpicsee take the standard fltk options? If so, then -title should already work.
Logged

The only barriers that can stop you are the ones you create yourself.
Pages: [1] 2 Go Up Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.11 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!