aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>2022-04-19 09:26:28 +0900
committer坂本 貴史 <o-takashi@sakamocchi.jp>2022-04-19 09:29:46 +0900
commit06efe91d44790a20a5c1e0e812ceee963d932f87 (patch)
treef6f9cf7642ce09fc675b9286f8160b0ee2ae3b64
parent3693514eff4bcc4f20f85b9c80c0617b230b47fa (diff)
downloadlibhinawa-06efe91d44790a20a5c1e0e812ceee963d932f87.tar.gz
snd_dice: link optimization to gi-docgen
The gi-docgen supports enhancement of inter-document link. This commit is optimization to it. Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
-rw-r--r--src/snd_dice.c42
-rw-r--r--src/snd_dice.h5
2 files changed, 20 insertions, 27 deletions
diff --git a/src/snd_dice.c b/src/snd_dice.c
index 8ecd8a1..9c7c81c 100644
--- a/src/snd_dice.c
+++ b/src/snd_dice.c
@@ -5,23 +5,20 @@
#include <errno.h>
/**
- * SECTION:snd_dice
- * @Title: HinawaSndDice
- * @Short_description: A notification listener for Dice models
- * @include: snd_dice.h
+ * HinawaSndDice:
+ * A notification listener for Dice models.
*
- * A #HinawaSndDice listen to Dice notification and generates signal when
- * received. This inherits #HinawaSndUnit.
+ * A [class@SndDice] listen to Dice notification and generates signal when received.
*/
/**
* hinawa_snd_dice_error_quark:
*
- * Return the GQuark for error domain of GError which has code in #HinawaSndDiceError.
+ * Return the [alias@GLib.Quark] for [struct@GLib.Error] which has code in Hinawa.SndDiceError.
*
* Since: 2.1
*
- * Returns: A #GQuark.
+ * Returns: A [alias@GLib.Quark].
*/
G_DEFINE_QUARK(hinawa-snd-dice-error-quark, hinawa_snd_dice_error)
@@ -71,11 +68,10 @@ static void hinawa_snd_dice_class_init(HinawaSndDiceClass *klass)
/**
* HinawaSndDice::notified:
- * @self: A #HinawaSndDice
+ * @self: A [class@SndDice]
* @message: A notification message
*
- * When Dice models transfer notification, the #HinawaSndDice::notified signal is
- * generated.
+ * Emitted when Dice unit transfers notification.
*
* Since: 0.3
*/
@@ -97,9 +93,9 @@ static void hinawa_snd_dice_init(HinawaSndDice *self)
/**
* hinawa_snd_dice_new:
*
- * Instantiate #HinawaSndDice object and return the instance.
+ * Instantiate [class@SndDice] object and return the instance.
*
- * Returns: an instance of #HinawaSndDice.
+ * Returns: an instance of [class@SndDice].
* Since: 1.3.
*/
HinawaSndDice *hinawa_snd_dice_new(void)
@@ -109,12 +105,12 @@ HinawaSndDice *hinawa_snd_dice_new(void)
/**
* hinawa_snd_dice_open:
- * @self: A #HinawaSndUnit
+ * @self: A [class@SndDice]
* @path: A full path of a special file for ALSA hwdep character device
- * @error: A #GError. Error can be generated with three domains; #g_file_error_quark(),
- * #hinawa_fw_node_error_quark(), and #hinawa_snd_unit_error_quark().
+ * @error: A [struct@GLib.Error]. Error can be generated with three domains; GLib.FileError,
+ * Hinawa.FwNodeError, and Hinawa.SndUnitError.
*
- * Open ALSA hwdep character device and check it for Dice devices.
+ * Open ALSA hwdep character device and check it for Dice devices.
*
* Since: 0.4
*/
@@ -140,17 +136,15 @@ void hinawa_snd_dice_open(HinawaSndDice *self, gchar *path, GError **error)
/**
* hinawa_snd_dice_transaction:
- * @self: A #HinawaSndDice
+ * @self: A [class@SndDice]
* @addr: A destination address of target device
- * @frame: (array length=frame_count)(in): An array with elements for quadlet
- * data to transmit.
+ * @frame: (array length=frame_count)(in): An array with elements for quadlet data to transmit.
* @frame_count: The number of quadlets in the frame.
* @bit_flag: bit flag to wait
- * @error: A #GError. Error can be generated with three domains; #hinawa_fw_node_error_quark(),
- * #hinawa_fw_req_error_quark(), and #hinawa_snd_dice_error_quark().
+ * @error: A [struct@GLib.Error]. Error can be generated with three domains; Hinawa.FwNodeError,
+ * Hinawa.FwReqError, and Hinawa.SndDiceError.
*
- * Execute write transactions to the given address, then wait and check
- * notification.
+ * Execute write transactions to the given address, then wait and check notification.
*
* Since: 1.4.
*/
diff --git a/src/snd_dice.h b/src/snd_dice.h
index 10a50a2..8656ed9 100644
--- a/src/snd_dice.h
+++ b/src/snd_dice.h
@@ -19,11 +19,10 @@ struct _HinawaSndDiceClass {
/**
* HinawaSndDiceClass::notified:
- * @self: A #HinawaSndDice
+ * @self: A [class@SndDice]
* @message: A notification message
*
- * When Dice models transfer notification, the #HinawaSndDiceClass::notified handler is
- * called.
+ * Class closure for the [signal@SndDice::notified].
*
* Since: 1.2
*/