Tagging in Krita

June 6, 2011 2 comments

Hi KDE folks,

        I am so glad to announce that Resource management part of my project is completed 🙂 and it is successfully merged into the main branch. I started working on the tagging functionality and UI part. In this week, I created a post with my ideas of tagging and posted it in the krita’s mailing list.

Some of the main points in tagging implementation are

  • QMultiHash Object – it is the one which we are using for storing tags for the resources. These will help for storing multi values i.e. many tags for the same resource. The searching functionality is also done faster by using this one.
  • UI Part – It is still under discussion. We are observing the tagging system in various applications, to find a good and better one. We are planning to implement two separate UI’s. One for searching tags and other for adding/removing tags.

            Here, I’m again mentioning the point why we are not using nepomuk because we want a tagging system which is compatible with the GIMP Tagging system. We need compatibility, so that we can exchange resources and tags easily.

Categories: Krita

Finishing Touches to Resource Management in Krita

May 30, 2011 2 comments

Hi KDE Planet,

       In this week, I prepared platform for doing next objective in my project i.e. tagging and also adding some finishing touches to the resource management part. I posted a review to check my present working branch “krita_resource-management-tagging-tiyyagura”, so that I can merge the branch into the master.

       I faced so many problems while building gimp on kubuntu Natty. I followed various tutorials and end up in errors. But this one is good, you can refer that when you want to build gimp in ubuntu.

        Coming to Resource management part, I changed the code of some functions in my commits, where I think there is a chance for decreasing the code. I updated the icons of the buttons in the GHNS Tool bar as suggested by pentalis and bugsbane. Still, I didn’t find a good icon for sharing resources. There is also no perfect icon in any application which represents uploading something (some icon designer can help by creating a new one 🙂 ).

And finally with these changes, I tried posting the review with post-review command but it is giving error like this

  File “/usr/lib/python2.7/httplib.py”, line 809, in _send_output

  msg += message_body

  UnicodeDecodeError: ‘ascii’ codec can’t decode byte 0xc5 in position 44353: ordinal not in range (128)

What may be the error ?

       I didn’t solve this error and so, I created a diff file between master and krita_resource-management-tagging-tiyyagura branch and posted that for review. Bowdewijn Rempt and Elvis stanswik already reviewed the code and suggested some changes. I did them, waiting for further suggestions and eager to merge the branch into master.

Categories: Krita

Resource Management for Presets in Krita

May 24, 2011 3 comments

Hi KDE Community,

I am glad to say that Resource management functionality is successfully added to presets resource :). Now its time to add this functionality to other resources in Krita :-/. The work I did in this week given me a lot of confidence and interest to do more.

1) A Bug fix

Firstly, I am thankful for Dave, cloose and JanKusanagi for there advice in fixing .knsrc file. With Daves comment, I thought of different distros and I asked Sven, about this one. He said that he noticed a bug in this issue and need to fix it. Then with cloose comment, I used the TargetDir instead of InstallPath with some modifications. Finally, it is fixed.

2) Blacklisting default resources

This functionality will come into stage when user want to delete default resource. The default files are not deleted but hidden from user by using blacklist file. Here, we added file names in an XML file and at startup, by using this XML file, we avoid to load these resources.

3) Changing resources

Whenever a user need to change a resource, then he can change the resource properties and then saves the resource file. This functionality is there already but changed a little bit.

4) Need Suggestion


These are buttons explanations

  • GHNS Upload button – It is the GHNS button, which executes the download widget of GHNS.
  • GHNS Download button – It is also the GHNS button, which executes the upload widget of GHNS.
  • Add Button – It helps to install the files which are downloaded directly without using GHNS.
  • Remove Button – This one removes the resource from the docker.

At remove button, we are facing the problem. The problem is

1). Whenever we installed some files using GHNS, the installed files are showing uninstall button in ghns dialog,

2). Now we remove these files using remove button.

3). And then we open GHNS dialog, the files which are removed using remove button are still showing uninstall option only.

Here, if we remove the files using remove button, the status of these files in cache registry are not updated. How can I do this thing ?

When I asked Frederik Gladhorn about this, he said to use the get hot new stuff api i.e. downloadManger to remove items. ( http://api.kde.org/4.x-api/kdelibs-apidocs/knewstuff/html/classKNS3_1_1DownloadManager.html ). But for using this class, we need entry object, which is not available here.

On the whole, this week work gave me satisfaction and I will do more in upcoming weeks 🙂

Categories: Krita

Enhancements in Krita GHNS Utility

May 16, 2011 4 comments

Hi Kde Community,

 In this week, I interacted with my mentor more and learned some new issues and committed two commits for GHNS.

 1). commit – 6cd1bbf92cdd0259d7a220ff4c9dc8a848947afb

 After downloading the resources using GHNS, they are not updating automatically in the docker section. This commit solves the problem by introducing a new function named “loadingResourceFile()” in libs/widgets/KoResourceServer.h. This function creates a resource using the downloaded file and adds it to the Resource server, which helps to upload the function.

 2). commit – f4e5d3a75008a93e25fc0b3491130fb84c357ef7

 In GHNS download dialog, once we select uninstall the resources, the resources are need to remove in docker but they are not updating. In this commit, this one is solved by using the above commit logic only.

Pic which shows the GHNS Dialog

 3). Thing I didn’t understand.

 -> While GHNS is running, it is giving the wrong address of the downloaded file

 Ex: /home/legend/.kde/share/apps/krita/paintoppresets//141694-TestPreset2.kpp — this one is the output address.

It should look like this /home/legend/.kde/share/apps/krita/paintoppresets/141694-TestPreset2.kpp.

here InstallPath = /home/legend/.kde/share/apps/krita/paintoppresets

FileName = 141694-TestPreset2.kpp

So, I think while joining these two, something is wrong. I didn’t getwhere this code is ?

 -> Another task is I didn’t get where GHNS is loading the status of the installed files. This one is used to remove files using remove button in the docker.

 I will fix these things as soon as possible. But this week, I enjoyed a lot in working with my mentor. 🙂

Categories: Krita

GHNS for preset resource in Krita

Hi KDE community,

      I enjoyed a lot in reading the blogs of my friends and especially the comments on my first blog :). In this week, I think I finally succeeded in setting the GHNS and it seems working well for presets tab. The things I did in this week are

1). I asked Frank Karlitschek to add these categories at present to opendesktop server

  • Krita Brushes
  • Krita Gradients
  • Krita patterns
  • Krita presets
  • Krita Shapes
  • Krita palettes

     Actually I asked so many categories that are present in krita.knsrc file but he asked me to decrease the number. So, I sent only these categories and in future we can increase the categories according to our need

2) In resourceItemChooser.cpp, I added a function called setGhnsFile() to load the knsrc file for required resource

       I think we have to use different knsrc files for different resources. But the present functionality is considering the default file krita.knsrc only. So, I added a function setGhnsFile() to specify the knsrc file and changed upload/download function to use our specified knsrc file.

3) Added a file called kritapresets.knsrc file for presets resource

     For krita presets, I added a new file to data directory of krita named kritapresets.knsrc file.

        I sent these changes patch to my mentor Sven and he aked me to commit the patch by creating a separate branch. I created a branch named krita_resource-management-tagging-tiyyagura and committed the patch to this branch. Look out this one and share your preset resources. . 🙂

Categories: Krita

My first week work in GSOC 2011

May 2, 2011 3 comments

Hi to all,

         This is my first blog after I got selected for GSOC-2011. My project is in Krita, under calligra and my task is “Tagging and Management for Krita Resources”. Here is the link for my project proposal http://www.google-melange.com/gsoc/proposal/review/google/gsoc2011/srikanth_tiyyagura/1. I am so thankful to Boudewijn rempt, who helped me from the start, i.e. from building Calligra to getting in GSOC 2011. And also thankful to the KDE community for helping me in getting GSOC especially KDE India people who did a good work by organizing kde.conf.in. I am so thankful to them.

         Then about my mentor Sven Langkamp, we started working together from the last week. I am a bit shy in interacting with people. So, I think I need some more time to mingle with my mentor. He is very patient in answering my stupid and silly questions.

         Then my work in first week (April 25 – May 1) is to study the Get Hot new stuff option implemented in presets tab and fix it as it was broken. I didn’t complete this one but I will speed up my work as fast as I can in the coming weeks. what I did in this week is reading through documentation and fixing up somethings.

This is the documentation I read through:

The things I fixed up are

1. Categories need to be updated for downloading resources.

GHNS need a file called appname.knsrc file, which is used to set configuration settings for upload or download dialog of GHNS. In krita, we have krita.knsrc file which contain categories like Krita Pixel Brush Presets, Krita Chalk Presets, Krita Curve Brush Presets, Krita Deform Brush Presets, Krita Duplicate Brush Presets and soon. But these categories are not in the provider server. Regarding this problem, I pinged Frederik Gladhorn who said that these categories are to be maintained at the servers and this work is done by Frank Karlitschek.I already mailed him and am waiting for his reply.
I think once this problem is corrected, we can easily download the resources from the server.

2. For uploading resources – updated a function

Upload option is not active. In order to make it active, I changed a function updateRemoveButtonState() to updateButtonState() in koResourceItemChooser.cpp and .h files and made the upload function active. But while using the upload dialog to share the resources, it is showing error saying that categories is not present in the server. So, this also needs the categories. I didn’t commit the change as the full functionality is not achieved.

On the whole, my opinion on this week is I need to speed up my work and need to develop more interaction with my mentor.

Categories: Krita

Here I start . . .

April 14, 2011 2 comments

Hi Friends,

I want to blog all the things done by me for Krita development. Krita is an application under calligra suite which is used for artists to draw images from scratch.

I did some stuff before but from today onwards I will blog all the work here.

Categories: Krita