John Giordano | 1 Aug 14:59 2008

Help with dragdrop

Hello:

  I have successfully built the dragdrop example under MSVC/windows.

  When I run it, the dragdrop.css file and the blue and red png files in the icons subdirectory are not found. (404 errors).

  I am in the DEBUG configuration.

  My docroot is set to period.

 

  I tried setting the current working directory to the directory with dragdrop.css and the icons directory. No luck.

  I even tried copying the executable (dragdrop.wt.exe) into the appropriate directory.

  I ran it from there and still no luck.

  Please help if you can.

  Thanks,

          -- John Paul

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
witty-interest mailing list
witty-interest@...
https://lists.sourceforge.net/lists/listinfo/witty-interest
Wim Dumon | 1 Aug 15:39 2008
Picon

Re: Help with dragdrop

John,

Thank you for your report, there is a bug there, which was introduced
in the previous release. Streams in windows apparently don't clear the
stream state, while on Linux this did not cause problems. Please apply
the patch below.

--- a/src/http/StaticReply.C
+++ b/src/http/StaticReply.C
 <at>  <at>  -33,8 +33,10  <at>  <at>  StaticReply::StaticReply(const std::string &full_path,
     if (stream_) {
       path_ = gzipPath;
       gzipReply = true;
-    } else
+    } else {
+      stream_.clear();
       stream_.open(path_.c_str(), std::ios::in | std::ios::binary);
+    }
   } else
     stream_.open(path_.c_str(), std::ios::in | std::ios::binary);

With respect to the examples, we recommend:
- Set docroot to the wt source tree (wt-.../examples/dragdrop)
- For examples using .xml resource files, set the working directory to
that location too
- For examples using stuff from the 'resources' directory, copy that
directory to that example's docroot

Regards,
Wim.

2008/8/1 John Giordano <jgiordano@...>:
> Hello:
>
>   I have successfully built the dragdrop example under MSVC/windows.
>
>   When I run it, the dragdrop.css file and the blue and red png files in the
> icons subdirectory are not found. (404 errors).
>
>   I am in the DEBUG configuration.
>
>   My docroot is set to period.
>
>
>
>   I tried setting the current working directory to the directory with
> dragdrop.css and the icons directory. No luck.
>
>   I even tried copying the executable (dragdrop.wt.exe) into the appropriate
> directory.
>
>   I ran it from there and still no luck.
>
>   Please help if you can.
>
>   Thanks,
>
>           -- John Paul
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> witty-interest mailing list
> witty-interest@...
> https://lists.sourceforge.net/lists/listinfo/witty-interest
>
>

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
John Giordano | 1 Aug 17:18 2008

Thank you

Hi:

  Thank you for the bug fix.

  It now works GREAT!!!

  One more question…

  I have .css/.js/png files but no .html files.

  Also there is no index.html file.

  Is there a way to tell Wt to generate .html files?

  That way I can copy all of the (.html/.css/.js/.png) files to another web server.

  I do realize that I would not be able to use (SSI) Server Side Includes.

  In other words, can I generate web server files without being tied to a particular web server? (apache, fastCGI, etc…)?

  Thanks again for all your help?

  I realize these may be stupid questions, but I think it is the only way to learn about Wt.

             -- John Paul

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
witty-interest mailing list
witty-interest@...
https://lists.sourceforge.net/lists/listinfo/witty-interest
Koen Deforche | 2 Aug 09:26 2008
Picon

Re: Ext::TableView with setDataLocation(Ext::ServerSide)

Hey Stefan,

2008/7/31 Stefan Haas <shaas@...>:
> delivered integers (column an row) of the cellClicked-signal apply to
> the current visible table (e.g. col 3 row 2) and not to the total
> WStandardItemModel (e.g. col 3 row 42 if PageSize is 20 and we're on
> page 2).

Oops! The cellClicked should indeed return row 42 since it should
return model indexes.

> Any ideas how to solve the problem?

By fixing this in TableView, which I now did. I'll push it to CVS
within the next few minutes/hours.

Thanks for spotting this!

Regards,
koen

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Koen Deforche | 2 Aug 10:25 2008
Picon

Re: SVG/VML/CANVAS rendering issues

Hey Arjan,

2008/7/31 Arjan Knepper <Arjan.Knepper@...>:
> First of all: great toolkit it saves me a lot of work!

Great to hear!

> Now the issues:
>
> This code renders different in Opera(8.51) and FF(3) vs IE(6) Opera and FF
> seems to do the right thing but IE doesn't. (with both VML and CANVAS)

This is now fixed in CVS, and the fix will be included in our next
release. Thanks for spotting this, it was a regression when trying to
deal with IE's messups on high DPI displays.

Note: IE does only VML (even if you ask for CANVAS). IE is the reason
why Canvas or SVG is not catching on since it only supports VML!

> Another issue is the rendering of  text using 'drawText' and resizing using
> the 'resize' member.
>
> FF always seems to preserve the initial size of the text in both SVG and
> CANVAS
>
> OPERA resizes OK in SVG but not in CANVAS

SVG and VML support text properly, while CANVAS does not (it is
emulated through HTML text). As a consequence, CANVAS text does not
react to the rotation and translation aspects of the transform. This
is one of the important reasons to prefer SVG over CANVAS.

The wrong behavior you see with Firefox + SVG, could it be explained
by using Firefox<3.0 on MacOS, which has broken SVG support and
therefore the toolkit does not support SVG? If not, what version of
Firefox and what operating system do you see this wrong behaviour
with?

Regards,
koen

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Koen Deforche | 2 Aug 10:43 2008
Picon

Re: WFileUpload progress.

Hey Jim,

2008/7/31 Jim Koornneef <jim@...>:
> Too bad about it being so deep in the code.  It would have been nice if
> there was an easy hack.  Oh well.

It will get implemented, eventually :-)

> Koen, one thing I noticed with 2.1.4 (I still need to update to 2.1.5, maybe
> it's fixed there?) is that you cannot set the buddy to WCheckBox.  If I
> create a WLabel and call setBuddy the code will all run fine until session
> logout/close.  At that point there are memory exceptions way deep in the
> delete code.  To reproduce, uncomment the call:
>
>        WLabel *over13Label = new WLabel(WString::tr("Over13"),
> layout->elementAt(a, 0));
>        new WBreak(layout->elementAt(a, 0));
>        O13ErrorLabel = new WLabel("&nbsp;", layout->elementAt(a, 0));
>        Over13Check = new WCheckBox(layout->elementAt(a, 1));
>        new WLabel(WString::tr("Over13Y"), layout->elementAt(a, 1));
> //      over13Label->setBuddy(Over13Check);     <-- No buddy?
>        a++;

I could not reproduce this, unfortunately (I do not think 2.1.4 or
current CVS will behave any differently).
Can you reproduce this in a small application? I would be very
interested in understanding this bug from a reproducible test case.

I tried these:

  WLabel *l = new WLabel("Ah", root());
  WCheckBox *c = new WCheckBox(root());
  l->setBuddy(c);

and

  WCheckBox *c = new WCheckBox(root());
  WLabel *l = new WLabel("Ah", root());
  l->setBuddy(c);

but did not get any errors when the session exits.

> I use this for session logout:
>        this->quit();

That's fine. It should be equivalent to stopping the built-in httpd
(e.g. using Ctrl-C). At all times all sessions are properly deleted!

Regards,
koen

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Maurice Gittens | 2 Aug 11:02 2008
Picon

Need some help with my first Wt program

Hi all,

I've been lurking around here for a while and I recently decided to get some hands on experience with Wt.
My first Wt program uses the WTreeTable and related classes and I can't seem to figure out why it does not work as expected.

I have two main issues (with Firefox and Konqueror on Fedora 9):
1. The program seems to never stop generating output to the browser. The text "stuff after treetable widget" keeps scrolling until it is no longer visible.
Then scollbars appear and scrolling continues until the scrollbar are really small.

This scrolling also happens when I do _not_ invoke the "filltable()" method.

Can anyone see my mistake?

2. I cannot seem to get the cell contents to align properly with their associated column names. This is probably due to me
not properly understanding the CSS/Wt interactions. Any help is appreciated.

The test program and the css file I am using are both attached.

Kind regards,
Maurice

Attachment (main.cpp): application/octet-stream, 4988 bytes
Attachment (test.css): text/css, 1195 bytes
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
witty-interest mailing list
witty-interest@...
https://lists.sourceforge.net/lists/listinfo/witty-interest
zhimin song | 2 Aug 17:16 2008
Picon

Please Help to Analyze Some Debug Info

hi, everyone,

       I have post some debug info below (It is just the debug info when login my app based on Wt, and then logout), can you tell me the main problems of my app, thanks.

----------------------------------------------------------
Caught SIGCHLD.
Child pid is 17478 stat = 139
Deleting session: gaekCSQqhvVnoiLx
Debugging Wt app...
Spawned new dedicated process: pid=17497
==17497== Memcheck, a memory error detector.
==17497== Copyright (C) 2002-2007, and GNU GPL'd, by Julian Seward et al.
==17497== Using LibVEX rev 1804, a library for dynamic binary translation.
==17497== Copyright (C) 2004-2007, and GNU GPL'd, by OpenWorks LLP.
==17497== Using valgrind-3.3.0-Debian, a dynamic binary instrumentation framework.
==17497== Copyright (C) 2000-2007, and GNU GPL'd, by Julian Seward et al.
==17497== For more details, rerun with: -v
==17497==
Reading Wt configuration from: /etc/wt/wt_config.xml
 binding property 'resources' with value 'resources/
 binding property 'extBaseURL' with value 'ext/
Session oXbi8hp2xEOygb1A created.
setting Debug
Sessions: 1
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.6) Gecko/20071008 Ubuntu/7.10 (gutsy) Firefox/2.0.0.6
Reading resource file: cx.xml
==17497== Thread 3:
==17497== Invalid read of size 4
==17497==    at 0x4014C37: (within /lib/ld-2.6.1.so)
==17497==    by 0x46650B1: (within /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x400D015: (within /lib/ld-2.6.1.so)
==17497==    by 0x4665274: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x463F7B6: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x463F8CF: (within /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x4641465: __nss_services_lookup (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x46474D4: getservbyname_r (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x464726D: getservbyname (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x481CD90: mysql_server_init (in /usr/lib/libmysqlclient.so.15.0.0)
==17497==    by 0x48433C1: mysql_init (in /usr/lib/libmysqlclient.so.15.0.0)
==17497==    by 0x43AC72A: mysqlpp::DBDriver::DBDriver() (dbdriver.cpp:48)
==17497==  Address 0x595a7b4 is 44 bytes inside a block of size 46 alloc'd
==17497==    at 0x4022AB8: malloc (vg_replace_malloc.c:207)
==17497==    by 0x400D123: (within /lib/ld-2.6.1.so)
==17497==    by 0x40081D8: (within /lib/ld-2.6.1.so)
==17497==    by 0x4010F83: (within /lib/ld-2.6.1.so)
==17497==    by 0x400D015: (within /lib/ld-2.6.1.so)
==17497==    by 0x401099D: (within /lib/ld-2.6.1.so)
==17497==    by 0x46650B1: (within /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x400D015: (within /lib/ld-2.6.1.so)
==17497==    by 0x4665274: __libc_dlopen_mode (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x463F7B6: __nss_lookup_function (in /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x463F8CF: (within /lib/tls/i686/cmov/libc-2.6.1.so)
==17497==    by 0x4641465: __nss_services_lookup (in /lib/tls/i686/cmov/libc-2.6.1.so)
Session exiting: oXbi8hp2xEOygb1A
Sessions: 0
Spawned new dedicated process: pid=17506
==17497==
==17497== Thread 2:
==17497== Invalid read of size 4
==17497==    at 0x4140D9E: Wt::WFormWidget::setValidator(Wt::WValidator*) (WFormWidget.C:202)
==17497==    by 0x41B4DE9: Wt::WValidator::~WValidator() (WValidator.C:20)
==17497==    by 0x4158725: Wt::WLengthValidator::~WLengthValidator() (WLengthValidator:26)
==17497==    by 0x4165D4E: Wt::WObject::~WObject() (WObject.C:78)
==17497==    by 0x417E4CE: Wt::WResource::~WResource() (WResource.C:30)
==17497==    by 0x41D323A: Wt::WWidget::~WWidget() (WWidget.C:38)
==17497==    by 0x41CE0E5: Wt::WWebWidget::~WWebWidget() (WWebWidget.C:169)
==17497==    by 0x414D8C8: Wt::WInteractWidget::~WInteractWidget() (WInteractWidget.C:46)
==17497==    by 0x413F9F5: Wt::WFormWidget::~WFormWidget() (WFormWidget.C:44)
==17497==    by 0x41A20CD: Wt::WTextArea::~WTextArea() (WTextArea:32)
==17497==    by 0x41CE04D: Wt::WWebWidget::~WWebWidget() (WWebWidget.C:158)
==17497==    by 0x414D8C8: Wt::WInteractWidget::~WInteractWidget() (WInteractWidget.C:46)
==17497==  Address 0x24 is not stack'd, malloc'd or (recently) free'd
==17497==
==17497== Process terminating with default action of signal 11 (SIGSEGV)
==17497==  Access not within mapped region at address 0x24
==17497==    at 0x4140D9E: Wt::WFormWidget::setValidator(Wt::WValidator*) (WFormWidget.C:202)
==17497==    by 0x41B4DE9: Wt::WValidator::~WValidator() (WValidator.C:20)
==17497==    by 0x4158725: Wt::WLengthValidator::~WLengthValidator() (WLengthValidator:26)
==17497==    by 0x4165D4E: Wt::WObject::~WObject() (WObject.C:78)
==17497==    by 0x417E4CE: Wt::WResource::~WResource() (WResource.C:30)
==17497==    by 0x41D323A: Wt::WWidget::~WWidget() (WWidget.C:38)
==17497==    by 0x41CE0E5: Wt::WWebWidget::~WWebWidget() (WWebWidget.C:169)
==17497==    by 0x414D8C8: Wt::WInteractWidget::~WInteractWidget() (WInteractWidget.C:46)
==17497==    by 0x413F9F5: Wt::WFormWidget::~WFormWidget() (WFormWidget.C:44)
==17497==    by 0x41A20CD: Wt::WTextArea::~WTextArea() (WTextArea:32)
==17497==    by 0x41CE04D: Wt::WWebWidget::~WWebWidget() (WWebWidget.C:158)
==17497==    by 0x414D8C8: Wt::WInteractWidget::~WInteractWidget() (WInteractWidget.C:46)
==17497==
==17497== ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 110 from 3)
==17497== malloc/free: in use at exit: 615,968 bytes in 12,892 blocks.
==17497== malloc/free: 103,830 allocs, 90,938 frees, 13,168,846 bytes allocated.
==17497== For counts of detected errors, rerun with: -v
==17497== searching for pointers to 12,892 not-freed blocks.
==17497== checked 18,366,216 bytes.
==17497==
==17497== LEAK SUMMARY:
==17497==    definitely lost: 0 bytes in 0 blocks.
==17497==      possibly lost: 130,905 bytes in 1,818 blocks.
==17497==    still reachable: 485,063 bytes in 11,074 blocks.
==17497==         suppressed: 0 bytes in 0 blocks.
==17497== Rerun with --leak-check=full to see details of leaked memory.
-------------------------------------------------------------------
Regards,
zhimsong
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
witty-interest mailing list
witty-interest@...
https://lists.sourceforge.net/lists/listinfo/witty-interest
Wim Dumon | 4 Aug 10:15 2008
Picon

Re: Thank you

2008/8/1 John Giordano <jgiordano@...>:
> Hi:
>
>   Thank you for the bug fix.
>
>   It now works GREAT!!!
>
>   One more question…
>
>   I have .css/.js/png files but no .html files.
>
>   Also there is no index.html file.
>
>   Is there a way to tell Wt to generate .html files?
>

No. A Wt program is exactly that - a program. Much like taking
screenshots won't replace the functionality of desktop programs,
static copies of Wt programs won't do anything useful.

Regards,
Wim.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
Maurice Gittens | 4 Aug 11:06 2008
Picon

Need some help with my first Wt program

Hi all,

I've been lurking around here for a while and I recently decided to get some hands on experience with Wt.
My first Wt program uses the WTreeTable and related classes and I can't seem to figure out why it does not work as expected.

I have two main issues (with Firefox and Konqueror on Fedora 9):
1. The program seems to never stop generating output to the browser. The text "stuff after treetable widget" keeps scrolling until it is no longer visible.
Then scollbars appear and scrolling continues until the scrollbar are really small.

This scrolling also happens when I do _not_ invoke the "filltable()" method.

Can anyone see my mistake?

2. I cannot seem to get the cell contents to align properly with their associated column names. This is probably due to me
not properly understanding the CSS/Wt interactions. Any help is appreciated.

The test program and the css file I am using are both attached.

Kind regards,
Maurice


Attachment (test.css): text/css, 1195 bytes
Attachment (main.cpp): application/octet-stream, 4988 bytes
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
witty-interest mailing list
witty-interest@...
https://lists.sourceforge.net/lists/listinfo/witty-interest

Gmane