Jump to content

GSoC/2016/StatusReports/Batyrenko Vladyslav

From KDE Community Wiki
Revision as of 09:06, 19 August 2016 by Mvlabat (talk | contribs) (grammatical fixes)

Introduction

Ark is an open source GUI tool for managing archives. It supports many archive types, such as 7z, zip, rar, tar and so on. For now Ark allows adding files and folders only the to root of an archive. As it happens that a user needs to edit the archive content, there has been a proposal to extend Ark functionalities in order to allow users to add new files to any destination, as well as rename, move or copy them. So my GSoC task was to implement those features.

Status

My first task, which was not directly related to the proposal, was to refactor two fundamental classes used to store metadata for archive entries. It was completed merging the classes into one and also choosing a new way to store the metadata: the QProperty system was utilized. All the features described in the proposal have been implemented and are functional.

Implemented features

  • Adding entries to specific destination. The existing action for adding files to the root was changed, so it can now be used for adding files everywhere. If the user selects a directory and uses the action, files will be added to the selected destination. Otherwise, If there is no selection or one or more files are selected, the new files will be added to the root as usual.
  • Renaming entries. Renaming allows users to change names of both files and folders. As in the Dolphin file manager, it can be called via the F2 shortcut and it is done in the inline lineedit widget, which makes Ark feel consistent with the main KDE file manager. There are also filenames checks provided, which limit user from entering slashes or use "." or ".." as filename.
  • Moving and copying entries. As in typical file managers, moving and copying are provided together with the "paste" action, which are accessible via CTRL+X, CTRL+C and CTRL+V shortcuts respectively. Users can move or copy files from different folders (which are expandable in the tree view) and paste them to the same destination at once. A folder can be copied into itself, but can not be moved. There are also checks for conflicting filenames implemented: users won't be able to copy or move files into a folder that has entries with the same names - that could lead to data loss.

Some numbers

# git diff master gsoc2016/master --stat
88 files changed, 4193 insertions(+), 1664 deletions(-)

Screenshots

Pasting entries. Here you can see that cutting one folder recursively selects all the inner entries and makes their icons grayed:

ark-pasting.png

Renaming entries is done via inline editing:

ark-renaming.png

Work Report