|
wlmaker
|
#include <libbase/libbase.h>#include <stdbool.h>#include <stdint.h>

Go to the source code of this file.
Classes | |
| struct | desktop_entry |
Enumerations | |
| enum | desktop_entry_type { DESKTOP_ENTRY_TYPE_UNKNOWN = 0 , DESKTOP_ENTRY_TYPE_APPLICATION = 1 , DESKTOP_ENTRY_TYPE_LINK = 2 , DESKTOP_ENTRY_TYPE_DIRECTORY = 3 } |
Functions | |
| struct desktop_parser * | desktop_parser_create (const char *locale_ptr) |
| void | desktop_parser_destroy (struct desktop_parser *parser) |
| int | desktop_parser_file_to_entry (const struct desktop_parser *parser, const char *fname_ptr, struct desktop_entry *entry_ptr) |
| int | desktop_parser_string_to_entry (const struct desktop_parser *parser, const char *string_ptr, struct desktop_entry *entry_ptr) |
| void | desktop_parser_entry_release (struct desktop_entry *entry_ptr) |
Variables | |
| const bs_test_set_t | desktop_parser_test_set |
Simple parser for FreeDesktop .desktop files, to provide application- specific information within a compositor and for constructing application menus. Depends on libinih-dev.
Reference:
Currently built to support the necessary keys for building the root menu for Wayland Maker. Specifically, that includes:
Further improvements:
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
| enum desktop_entry_type |
Permissible values for Type=....
| struct desktop_parser * desktop_parser_create | ( | const char * | locale_ptr | ) |
Creates a desktop parser, using the provided locale.
| locale_ptr | Locale set for LC_MESSAGES. See setlocale(3). |
| void desktop_parser_destroy | ( | struct desktop_parser * | parser | ) |
Destroys the desktop parser.
| parser |
| void desktop_parser_entry_release | ( | struct desktop_entry * | entry_ptr | ) |
Releases the resources associated to the entry.
| entry_ptr |
| int desktop_parser_file_to_entry | ( | const struct desktop_parser * | parser, |
| const char * | fname_ptr, | ||
| struct desktop_entry * | entry_ptr ) |
Parses a file into the provided entry.
| parser | |
| fname_ptr | |
| entry_ptr |
| int desktop_parser_string_to_entry | ( | const struct desktop_parser * | parser, |
| const char * | string_ptr, | ||
| struct desktop_entry * | entry_ptr ) |
Parses an in-memory string into the provided entry.
| parser | |
| string_ptr | |
| entry_ptr |
|
extern |
Unit test set.