Bug 121800 - can't setup camera correctly
Summary: can't setup camera correctly
Status: RESOLVED NOT A BUG
Alias: None
Product: digikam
Classification: Applications
Component: Import-Gphoto2 (show other bugs)
Version: 0.7.2
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-11 23:27 UTC by Horst
Modified: 2017-08-16 06:13 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 0.9.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Horst 2006-02-11 23:27:08 UTC
Version:           0.7.2 (using KDE 3.4.0 Level "b" , SUSE 9.3)
Compiler:          gcc version 3.3.5 20050117 (prerelease) (SUSE Linux)
OS:                Linux (i586) release 2.6.11.4-21.10-default

1. I'm a new user of digicam. My camera is HP Photo Smart C200
Now the description of my problem follows:
As I started the program the first time logged in as normal user, my cam wasn't found by autodetect. Manual addition from the camera-list was possible, but I ccouldn't set the serial port it is connected to. Each try to access the cam failed.
Logged in as root autodetect also failed, but manual addition worked. I can download pictures and do all the things I want to do under normal user account.
I've tried several things to get it work as normal user. First I added the cam in KDE Control Center, where I also could specify the serial port, but digicam didn't change its behaviour. Even the addition of my user account to group root and set this as standard group didn't allow functionally setup of my cam. Now I have no more idea to get a working setup.
On startup digicam loads 14 KIPI-Plugins, I don't have any other programs running when I use digicam (except programs started during login process), allthough my machine has 512MB RAM installed and works with 1GB swap.
Comment 1 caulier.gilles 2006-04-03 11:41:03 UTC
SVN commit 525916 by cgilles:

digikam from trunk : Polishing and improving camera setup dialog. Add Tips on the bottom about how to set USB mass Storage camera. Add web Link to fresh cameras list supported by GPhoto2.
CCMAIL: digikam-devel@kde.org
CCBUGS: 121800, 121784

 M  +55 -68    cameraselection.cpp  


--- trunk/extragear/graphics/digikam/utilities/setup/cameraselection.cpp #525915:525916
@@ -25,7 +25,6 @@
 #include <qcombobox.h>
 #include <qgroupbox.h>
 #include <qlabel.h>
-#include <qlistview.h>
 #include <qpushbutton.h>
 #include <qradiobutton.h>
 #include <qvbuttongroup.h>
@@ -37,8 +36,10 @@
 // KDE includes.
 
 #include <kglobalsettings.h>
+#include <kactivelabel.h>
 #include <kurlrequester.h>
 #include <klocale.h>
+#include <klistview.h>
 
 // Local includes.
 
@@ -64,8 +65,6 @@
         umsMountURL      = 0;
     }
 
-    QListView     *listView;
-
     QLineEdit     *titleEdit;
 
     QVButtonGroup *portButtonGroup;
@@ -81,6 +80,8 @@
     QString        UMSCameraNameShown;
 
     QStringList    serialPortList;
+    
+    KListView     *listView;
 
     KURLRequester *umsMountURL;
 };
@@ -97,40 +98,33 @@
     QWidget *page = new QWidget( this );
     setMainWidget(page);
     
-    QVBoxLayout *topLayout =
-        new QVBoxLayout( page, 5, 5 ); 
+    QVBoxLayout *topLayout = new QVBoxLayout( page, 5, 5 ); 
 
-    QGroupBox* mainBox = new QGroupBox( page );
-    mainBox->setTitle( i18n( "Camera Configuration" ) );
-    mainBox->setColumnLayout(0, Qt::Vertical );
-    mainBox->layout()->setSpacing( 5 );
-    mainBox->layout()->setMargin( 5 );
-    QGridLayout* mainBoxLayout = new QGridLayout( mainBox->layout() );
-    mainBoxLayout->setAlignment( Qt::AlignTop );
+    // --------------------------------------------------------------
 
-    d->listView = new QListView( mainBox );
-    d->listView->addColumn( i18n("Cameras") );
-    d->listView->setSizePolicy(QSizePolicy(QSizePolicy::Expanding,
-                                         QSizePolicy::Expanding));
-    mainBoxLayout->addMultiCellWidget( d->listView, 0, 4, 0, 0 );
+    QGroupBox* mainBox = new QGroupBox( 0, Qt::Vertical, i18n( "Camera Configuration" ), page );
+    mainBox->setInsideMargin(KDialogBase::marginHint());
+    mainBox->setInsideSpacing(KDialogBase::spacingHint());  
+    
+    QGridLayout* mainBoxLayout = new QGridLayout( mainBox->layout(), 5, 1, KDialog::spacingHint() );
+    
+    // --------------------------------------------------------------
 
-    QGroupBox* titleBox = new QGroupBox( mainBox );
-    titleBox->setTitle( i18n("Camera Title") );
-    titleBox->setColumnLayout(0, Qt::Vertical );
-    titleBox->layout()->setSpacing( 5 );
-    titleBox->layout()->setMargin( 5 );
-    QVBoxLayout* titleBoxLayout = new QVBoxLayout( titleBox->layout() );
+    d->listView = new KListView( mainBox );
+    d->listView->addColumn( i18n("Camera List") );
+    d->listView->setAllColumnsShowFocus(true);
+    d->listView->setResizeMode(KListView::LastColumn);
+    d->listView->setMinimumWidth(350);
 
-    d->titleEdit = new QLineEdit( titleBox );
-    titleBoxLayout->addWidget( d->titleEdit );
+    // --------------------------------------------------------------
 
-    mainBoxLayout->addWidget( titleBox, 0, 1 );
+    QGroupBox* titleBox = new QGroupBox( 1, Qt::Vertical, i18n("Camera Title"), mainBox );
+    d->titleEdit = new QLineEdit( titleBox );
     
-    d->portButtonGroup = new QVButtonGroup( mainBox );
-    d->portButtonGroup->setTitle( i18n( "Camera Port Type" ) );
+    // --------------------------------------------------------------
+    
+    d->portButtonGroup = new QVButtonGroup( i18n("Camera Port Type"), mainBox );
     d->portButtonGroup->setRadioButtonExclusive( true );
-    d->portButtonGroup->layout()->setSpacing( 5 );
-    d->portButtonGroup->layout()->setMargin( 5 );
 
     d->usbButton = new QRadioButton( d->portButtonGroup );
     d->usbButton->setText( i18n( "USB" ) );
@@ -138,51 +132,44 @@
     d->serialButton = new QRadioButton( d->portButtonGroup );
     d->serialButton->setText( i18n( "Serial" ) );
 
-    mainBoxLayout->addWidget( d->portButtonGroup, 1, 1 );
-
-    QGroupBox* portPathBox = new QGroupBox( mainBox );
-    portPathBox->setTitle( i18n( "Camera Port Path" ) );
-    portPathBox->setColumnLayout(0, Qt::Vertical );
-    portPathBox->layout()->setSpacing( 5 );
-    portPathBox->layout()->setMargin( 5 );
-    QVBoxLayout* portPathBoxLayout = new QVBoxLayout( portPathBox->layout() );
-    portPathBoxLayout->setAlignment( Qt::AlignTop );
-
+    // --------------------------------------------------------------
+    
+    QGroupBox* portPathBox = new QGroupBox( 1, Qt::Horizontal, i18n( "Camera Port Path" ), mainBox );
     d->portPathLabel = new QLabel( portPathBox);
-    d->portPathLabel->setText( i18n( "only for serial port\n"
-			             "cameras" ) );
-    portPathBoxLayout->addWidget( d->portPathLabel );
+    d->portPathLabel->setText( i18n( "Note: only for serial port camera" ) );
 
     d->portPathComboBox = new QComboBox( false, portPathBox );
     d->portPathComboBox->setDuplicatesEnabled( false );
-    portPathBoxLayout->addWidget( d->portPathComboBox );
 
-    mainBoxLayout->addWidget( portPathBox, 2, 1 );
+    // --------------------------------------------------------------
 
-    QGroupBox* umsMountBox = new QGroupBox( mainBox );
-    umsMountBox->setTitle( i18n( "Camera Mount Path" ) );
-    umsMountBox->setColumnLayout(0, Qt::Vertical );
-    umsMountBox->layout()->setSpacing( 5 );
-    umsMountBox->layout()->setMargin( 5 );
-    QVBoxLayout* umsMountBoxLayout = new QVBoxLayout( umsMountBox->layout() );
-    umsMountBoxLayout->setAlignment( Qt::AlignTop );
+    QGroupBox* umsMountBox = new QGroupBox( 1, Qt::Horizontal, i18n( "Camera Mount Path"), mainBox );
 
     QLabel* umsMountLabel = new QLabel( umsMountBox );
-    umsMountLabel->setText( i18n( "only for USB/IEEE mass storage\n"
-                                  "cameras" ) );
-    umsMountBoxLayout->addWidget( umsMountLabel );
+    umsMountLabel->setText( i18n( "Note: only for USB/IEEE mass storage camera" ) );
 
     d->umsMountURL = new KURLRequester( QString("/mnt/camera"), umsMountBox);
     d->umsMountURL->setMode(KFile::Directory | KFile::ExistingOnly | KFile::LocalOnly);
+    
+    // --------------------------------------------------------------
+    
+    KActiveLabel* explanation = new KActiveLabel(mainBox);
+    explanation->setText(i18n("<p>To set an <b>Usb Mass Storage</b> camera, please use <b>%1</b> from camera list.<p> "
+                              "<p>To see a fresh list of supported cameras, take a look at "
+                              "<a href='http://www.teaser.fr/~hfiguiere/linux/digicam.html'>this url</a>.</p>")
+                              .arg(d->UMSCameraNameShown));    
 
-    umsMountBoxLayout->addWidget( d->umsMountURL );
-    mainBoxLayout->addWidget( umsMountBox, 3, 1 );
+    // --------------------------------------------------------------
+    
+    mainBoxLayout->addMultiCellWidget( d->listView, 0, 5, 0, 0 );
+    mainBoxLayout->addMultiCellWidget( titleBox, 0, 0, 1, 1 );
+    mainBoxLayout->addMultiCellWidget( d->portButtonGroup, 1, 1, 1, 1 );
+    mainBoxLayout->addMultiCellWidget( portPathBox, 2, 2, 1, 1 );
+    mainBoxLayout->addMultiCellWidget( umsMountBox, 3, 3, 1, 1 );
+    mainBoxLayout->addMultiCellWidget( explanation, 4, 4, 1, 1 );
+    mainBoxLayout->setColStretch( 0, 10 );
+    mainBoxLayout->setRowStretch( 5, 10 );
 
-    QSpacerItem* spacer = new QSpacerItem( 20, 20,
-                                           QSizePolicy::Minimum,
-                                           QSizePolicy::Expanding );
-    mainBoxLayout->addItem( spacer, 4, 1 );
-
     topLayout->addWidget( mainBox );
 
     // Connections --------------------------------------------------
@@ -246,17 +233,17 @@
 {
     int count = 0;
     QStringList clist;
-
-    GPIface::getSupportedCameras(count, clist);
-
     QString cname;
-    for (int i=0; i<count; i++) 
+    
+    GPIface::getSupportedCameras(count, clist);
+    
+    for (int i = 0 ; i < count ; i++) 
     {
         cname = clist[i];
         if (cname == d->UMSCameraNameActual)
-            new QListViewItem(d->listView, d->UMSCameraNameShown);
+            new KListViewItem(d->listView, d->UMSCameraNameShown);
         else
-            new QListViewItem(d->listView, cname);
+            new KListViewItem(d->listView, cname);
     }
 }
 
Comment 2 caulier.gilles 2006-07-18 09:44:15 UTC
0.7.2 is a too older digiKam version. I recommend you to try a recnt release (0.8.2 for example, or better 0.9.0-beta1) using the last libbphoto2.2 release.

Gilles Caulier
Comment 3 Horst 2006-07-25 19:50:01 UTC
First I have to say sorry...

I have experienced many problems with my system in the last month's... think it was simply a too old pc (amd k6II-500 on a noname-mainboard). Some hardware-defekts in the last weeks caused me to buy a new one and after re-installing my linux-version and update to digikam 0.8.2 now everything works fine. Thank you for your support... I hope it wasn't too much work for you.
Comment 4 caulier.gilles 2006-07-25 21:27:08 UTC
ok. thanks for the report. I close this file now...

Gilles